http://bugs.winehq.org/show_bug.cgi?id=16948
Summary: tmpfile() write, seek(0) and read does not return same data Product: Wine Version: unspecified Platform: All OS/Version: Linux Status: UNCONFIRMED Severity: enhancement Priority: P2 Component: -unknown AssignedTo: wine-bugs@winehq.org ReportedBy: lkcl@lkcl.net
ok this is tested from python (import os) so it _could_ be done a little simpler - like... using c. didn't want to forget about it so am raising it here.
this is the mode opening a tmpfile:
fixme:msvcrt:MSVCRT__sopen : pmode 0x1464e0 ignored
http://bugs.python.org/issue4956 $ ./python.exe -i Python 2.5.2 (r252:60911, Jan 15 2009, 23:28:55) [gcc] on win32 Type "help", "copyright", "credits" or "license" for more information.
import os f = os.tmpfile() f.name
'<tmpfile>'
f.write("hello\n") f.flush() f
<open file '<tmpfile>', mode 'w+b' at 0x001B34E8>
f.tell()
6L
f.seek(0) f.tell()
0L
f.read()
''
it's as if it's impossible to read from the tmpfile. which kinda defeats the object of having one :)
c:\windows\temp exists but c:\windows\tmp does not.