[issue5887] mmap.write_byte out of bounds - no error, position gets screwed up
Brian Mearns bmea...@ieee.org added the comment: Confirmed fixed in python 2.6.2 -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue5887 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue5887] mmap.write_byte out of bounds - no error, position gets screwed up
Hirokazu Yamamoto ocean-c...@m2.ccsnet.ne.jp added the comment: Thank you for response. I'll close this entry. -- resolution: - out of date status: open - closed ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue5887 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue5887] mmap.write_byte out of bounds - no error, position gets screwed up
Brian Mearns bmea...@ieee.org added the comment: On Wed, May 6, 2009 at 8:51 AM, Hirokazu Yamamoto rep...@bugs.python.org wrote: Hirokazu Yamamoto ocean-c...@m2.ccsnet.ne.jp added the comment: Thank you for response. I'll close this entry. -- resolution: - out of date status: open - closed Ok, thanks. I wasn't sure if I should close it or not. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue5887 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue5887] mmap.write_byte out of bounds - no error, position gets screwed up
Hirokazu Yamamoto ocean-c...@m2.ccsnet.ne.jp added the comment: Can you try this with Python2.6.2? I believe this bug got fixed. -- nosy: +ocean-city ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue5887 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue5887] mmap.write_byte out of bounds - no error, position gets screwed up
New submission from Brian Mearns bmea...@ieee.org: Created an mmap for a file in update mode, seek to end of file, and invoke write_byte. The file is not updated (as expected), but did not get any error indicating the write was out of bounds, and when I invoke tell(), it reports a position that is out of bounds. I check size(), and it still reports the correct size (less than the value reported by tell()). If I do seek(0, os.SEEK_END), it correctly returns to the end of the map, instead of this bizarre no-mans land beyond the end. This is on Windows XP. Here's an example from the shell. (note that write() works as I would expect, it raises an exception and doesn't modify the position): map.tell() 0 map.size() 8 map.seek(0, os.SEEK_END) map.tell() 8 map.write(foo) Traceback (most recent call last): File stdin, line 1, in module ValueError: data out of range map.tell() 8 map.size() 8 map.write_byte('x') map.tell() 9 map.size() 8 print WTF? WTF? map.write_byte('x') map.tell() 10 map.size() 8 map.flush() 1 map.size() 8 map.tell() 10 map.seek(0, os.SEEK_END) map.tell() 8 map.size() 8 -- messages: 86848 nosy: bmearns severity: normal status: open title: mmap.write_byte out of bounds - no error, position gets screwed up type: behavior versions: Python 2.6 ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue5887 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com