Pascal Chambon <chambon.pas...@gmail.com> added the comment: Thanks for the detailed feedback.
According to what you said (and to details found in python docs), the current _fileio.truncate is actually quite buggy -> no reference counting ops were done on posobj, even though it's sometimes retrieved from _portable_seek, and returned or not depending on rare error cases (SetEndOfFile failing etc.). Here is a patch fixing all that for python2.6, I've tested it manually in debug mode, and against memoryio/io/fileio tests ; hope it will be OK. As soon as this one is certified, I'll prepare a patch for python2.7 ---------- Added file: http://bugs.python.org/file15909/patch26_truncate_pos_refcounts.patch _______________________________________ Python tracker <rep...@bugs.python.org> <http://bugs.python.org/issue6939> _______________________________________ _______________________________________________ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com