On Jun 6, 10:18 am, [EMAIL PROTECTED] wrote:
<snippage>
> This code works PERFECTLY in Linux.  Where I have a match in the file
> I'm processing, it gets cut out from the start of the match until the
> end of the match, and written to the temporary file in tempdir.
> It does not work in Windows.  It does not create or write to the
> temporary file AT ALL.  It creates the tempdir directory with no
> problem.

In general, I don't use string concatenation when building paths.
Especially on scripts that are meant to run on multiple platforms.


> Here's the kicker: it works perfectly in Windows if Windows is running
> in VMware on a Linux host!  (I assume that that's because VMware is
> passing some call to the host.)

probably a red herring.

> Can anyone tell me what it is that I'm missing which would prevent the
> file from being created on Windows natively?

Get rid of the 'posix' check and use os.path.join to create
'tempfileName' and see if it works.

HTH.
...
Jay Graves
--
http://mail.python.org/mailman/listinfo/python-list

Reply via email to