New submission from Hallvard B Furuseth <h.b.furus...@usit.uio.no>: errno is sometimes read too late after the error: After another call may have modified it. Here's a patch against py3k. Most of it or a variant applies to 2.7 too, but I haven't really looked at that.
I've not looked at math code, where I don't even know what sets errno. There might also be a late errno read at Modules/_ctypes/callproc.c line 794: "space[0] = errno;". Does it want the errno from before _ctypes_get_errobj()? I'm unsure what's going on there. Modules/_multiprocessing/semaphore.c doesn't need the patch's extra variable, it can instead be rearranged with the commented-out patch. ---------- components: None files: late-errno.diff keywords: patch messages: 120719 nosy: hfuru priority: normal severity: normal status: open title: errno is read too late type: behavior versions: Python 2.7, Python 3.1, Python 3.2 Added file: http://bugs.python.org/file19539/late-errno.diff _______________________________________ Python tracker <rep...@bugs.python.org> <http://bugs.python.org/issue10350> _______________________________________ _______________________________________________ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com