New submission from Byron Hawkins <byron.c.hawk...@gmail.com>: open_file = open("file.txt", "r+b") file_map = mmap.mmap(open_file, 0) file_map.seek(offset) file_map.write("foobar") # success file_map.flush() # success file_map.flush(offset, len("foobar")) # Fails with "errno 22"
This example passes correct arguments to mmap.flush(), yet it fails with errno 22. So the arguments are not valid on linux. If the bug cannot be fixed, then all reference to those two arguments should be removed from the code and documentation related to Linux. ---------- components: Library (Lib) messages: 311832 nosy: byronhawkins priority: normal severity: normal status: open title: mmap.flush() on Linux does not accept the "offset" and "size" args type: crash versions: Python 2.7 _______________________________________ Python tracker <rep...@bugs.python.org> <https://bugs.python.org/issue32798> _______________________________________ _______________________________________________ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com