[issue2730] file readline w+ memory dumps

2008-05-01 Thread Amaury Forgeot d'Arc
Amaury Forgeot d'Arc <[EMAIL PROTECTED]> added the comment: This is a duplicate of issue1394612, which was closed as "invalid". See the discussion there: - "in standard C mixing reads with writes yields undefined behavior [...] If you want defined behavior, then, for example, add >>> f.seek(0) b

[issue2730] file readline w+ memory dumps

2008-05-01 Thread tempname
New submission from tempname <[EMAIL PROTECTED]>: the following code actually dumps the heap into the temp file... very strange. Make sure the file doesn't exist before running the script. Only the list of numbers should be written to the file, but alot of junk is added. x = str(range(10)) f = o