[issue29082] In 2.7.13, _ctypes.LoadLibrary no longer accepts Unicode objects

2017-01-12 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: Committed with changed test. Thank you for your patch Chi Hsuan Yen. -- resolution: -> fixed stage: patch review -> resolved status: open -> closed ___ Python tracker

[issue29082] In 2.7.13, _ctypes.LoadLibrary no longer accepts Unicode objects

2017-01-12 Thread Roundup Robot
Roundup Robot added the comment: New changeset 4ce22d69e134 by Serhiy Storchaka in branch '2.7': Issue #29082: Fixed loading libraries in ctypes by unicode names on Windows. https://hg.python.org/cpython/rev/4ce22d69e134 -- nosy: +python-dev ___

[issue29082] In 2.7.13, _ctypes.LoadLibrary no longer accepts Unicode objects

2017-01-12 Thread Serhiy Storchaka
Changes by Serhiy Storchaka : -- assignee: -> serhiy.storchaka ___ Python tracker ___

[issue29082] In 2.7.13, _ctypes.LoadLibrary no longer accepts Unicode objects

2017-01-12 Thread Chi Hsuan Yen
Chi Hsuan Yen added the comment: Here's a new patch using fake library names. And thanks for those related issues about asdl_c.py! -- Added file: http://bugs.python.org/file46273/issue29082_3.patch ___ Python tracker

[issue29082] In 2.7.13, _ctypes.LoadLibrary no longer accepts Unicode objects

2017-01-07 Thread Martin Panter
Martin Panter added the comment: Other tests are skipped if libc_name is None, so your assertion is inconsistent. FTR there are reports open about problems with bootstrap files like asdl_c.py, e.g. Issue 28143 proposing to port that file to Python 3, and Issue 23404 about the future of “make

[issue29082] In 2.7.13, _ctypes.LoadLibrary no longer accepts Unicode objects

2016-12-31 Thread Chi Hsuan Yen
Chi Hsuan Yen added the comment: Oops, Parser/asdl_c.py shouldn't be included. Here's the correct patch -- Added file: http://bugs.python.org/file46103/issue29082.patch ___ Python tracker

[issue29082] In 2.7.13, _ctypes.LoadLibrary no longer accepts Unicode objects

2016-12-31 Thread Chi Hsuan Yen
Chi Hsuan Yen added the comment: I finally get Windows builds working. Here's the patch. -- Added file: http://bugs.python.org/file46102/issue29082.patch ___ Python tracker

[issue29082] In 2.7.13, _ctypes.LoadLibrary no longer accepts Unicode objects

2016-12-31 Thread Chi Hsuan Yen
Changes by Chi Hsuan Yen : Removed file: http://bugs.python.org/file46055/LoadLibrary_revert_arg_parsing.patch ___ Python tracker ___

[issue29082] In 2.7.13, _ctypes.LoadLibrary no longer accepts Unicode objects

2016-12-27 Thread Chi Hsuan Yen
Chi Hsuan Yen added the comment: Sorry, but I'm afraid of being unable to test it. I tried to setup a Windows build environment for 2.x but failed. (I've once successfully built 3.x on Windows for issue25939, but things seems different now :( -- keywords: +patch Added file:

[issue29082] In 2.7.13, _ctypes.LoadLibrary no longer accepts Unicode objects

2016-12-27 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: Good catch Chi Hsuan Yen! This is my mistake, I though PyString_Size() works only with str (as many similar *_Size() functions). Agreed, this change should be reverted. Do you want provide the patch with tests? -- keywords: +easy (C) stage: ->

[issue29082] In 2.7.13, _ctypes.LoadLibrary no longer accepts Unicode objects

2016-12-27 Thread Chi Hsuan Yen
New submission from Chi Hsuan Yen: In issue27330, there's one more change besides fixing possible memory leaks. In LoadLibrary function of _ctypes: [1] -if (!PyArg_ParseTuple(args, "O|O:LoadLibrary", , )) +if (!PyArg_ParseTuple(args, "S|O:LoadLibrary", , )) Before this change, both