[issue26671] Clean up path_converter in posixmodule.c

2016-04-07 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: Thank you Martin. -- status: open -> closed ___ Python tracker ___ ___ Python-bugs-list mailing li

[issue26671] Clean up path_converter in posixmodule.c

2016-04-07 Thread Roundup Robot
Roundup Robot added the comment: New changeset 633bb190fb76 by Serhiy Storchaka in branch 'default': Issue #26671: Fixed tests for changed error messages. https://hg.python.org/cpython/rev/633bb190fb76 -- ___ Python tracker

[issue26671] Clean up path_converter in posixmodule.c

2016-04-07 Thread Martin Panter
Martin Panter added the comment: Looks like the tests may need updating for a changed exception message: http://buildbot.python.org/all/builders/x86%20Ubuntu%20Shared%203.x/builds/12996/steps/test/logs/stdio == FAIL: test_stat (

[issue26671] Clean up path_converter in posixmodule.c

2016-04-06 Thread Roundup Robot
Roundup Robot added the comment: New changeset 8dc144e47252 by Serhiy Storchaka in branch 'default': Issue #26671: Fixed #ifdef indentation. https://hg.python.org/cpython/rev/8dc144e47252 -- ___ Python tracker

[issue26671] Clean up path_converter in posixmodule.c

2016-04-06 Thread Roundup Robot
Roundup Robot added the comment: New changeset 4acdb324a430 by Serhiy Storchaka in branch 'default': Issue #26671: Fixed #ifdef indentation. https://hg.python.org/cpython/rev/4acdb324a430 -- ___ Python tracker

[issue26671] Clean up path_converter in posixmodule.c

2016-04-06 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: Thank you for your review Larry. -- resolution: -> fixed stage: patch review -> resolved status: open -> closed ___ Python tracker ___ __

[issue26671] Clean up path_converter in posixmodule.c

2016-04-06 Thread Roundup Robot
Roundup Robot added the comment: New changeset a866f5727b7f by Serhiy Storchaka in branch 'default': Issue #26671: Enhanced path_converter. https://hg.python.org/cpython/rev/a866f5727b7f -- nosy: +python-dev ___ Python tracker

[issue26671] Clean up path_converter in posixmodule.c

2016-04-06 Thread Larry Hastings
Larry Hastings added the comment: LGTM. -- ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.

[issue26671] Clean up path_converter in posixmodule.c

2016-04-06 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: Here it is. -- Added file: http://bugs.python.org/file42380/path_converter_cleanup_3.patch ___ Python tracker ___

[issue26671] Clean up path_converter in posixmodule.c

2016-04-06 Thread Larry Hastings
Larry Hastings added the comment: Can you post the updated patch please? -- ___ Python tracker ___ ___ Python-bugs-list mailing list U

[issue26671] Clean up path_converter in posixmodule.c

2016-04-01 Thread STINNER Victor
Changes by STINNER Victor : -- nosy: +haypo ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python

[issue26671] Clean up path_converter in posixmodule.c

2016-04-01 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: Good catch! Here is updated patch. It fixes also hiding exception in dir_fd converter. -- Added file: http://bugs.python.org/file42341/path_converter_cleanup_2.patch ___ Python tracker

[issue26671] Clean up path_converter in posixmodule.c

2016-03-31 Thread Larry Hastings
Larry Hastings added the comment: I approve in principle, but this patch isn't ready. If we compile on Win32, and allow_fd is on, and they pass in an invalid fd, your patched code will reach line 914 "length = PyBytes_GET_SIZE(bytes);" but bytes will be uninitialized. --

[issue26671] Clean up path_converter in posixmodule.c

2016-03-30 Thread Serhiy Storchaka
New submission from Serhiy Storchaka: path_converter in Modules/posixmodule.c sequentially tries to convert an argument to str, bytes, and int. If previous conversion is failed, it clears the error and tries with type. This can hide some errors (such as MemoryError) and even cause using unexpe