Embedding (PyRun_SimpleFile)

nick_knight at my-deja.com nick_knight at my-deja.com
Thu Aug 3 07:33:37 EDT 2000


In article <5Bai5.476$Ln4.3695 at news-server.bigpond.net.au>,
  "Mark Hammond" <MarkH at ActiveState.com> wrote:
> <nick_knight at my-deja.com> wrote in message
> news:8mb34n$5c6$1 at nnrp1.deja.com...
> > In article <8F848A917gmcmhypernetcom at 199.171.54.154>,
> >   gmcm at hypernet.com (Gordon McMillan) wrote:
> > > nick_knight at my-deja.com wrote:
> > >
> > > >gets printed out to stdio, also when the program enters
> > > >PyRun_SimpleFile MSVC comes up with a unhandled exeption
> > >
> > > Since you can't be bothered to tell us what the exception is, I'll
> > guess
> > > that you're not using the same c runtime Python is, so when you
pass
> > that
> > > FILE * from your code to Python, msvcrt.dll (which is what Python
> > uses)
> > > doesn't like it.
> > >
> > > -Gordon
> > >
> > I appologise - I should have been more specific, Windows reports
> > Unhandled Exeption in testbed.exe(KERNEL32.dll) 0x0000005 Access
> > Violation,  this is occurring in file /Parser/tokenizer.c on line
270
> > (when it attemtps to read a line from the file)
>
> Gordon is almost certainly correct in his (slightly curt ;-)
diagnoses.
> Ensure you are using /MD (or /MDd for debug builds).  See the FAQ and
lots
> of other notes - it is critical you select the correct C runtime
library.
>
> Mark.
>
>

Thanks for that - that did the trick - just work on the sys.path now.


Sent via Deja.com http://www.deja.com/
Before you buy.



More information about the Python-list mailing list