Change in behavior (bug) in ctypes

Marvin Greenberg public.marvin@gmail.com
Thu Jun 30 14:22:00 GMT 2016


Code like this was working until sometime recently,
$ python
 >>> import ctypes
 >>> cygdll = ctypes.cdll.cygwin1
But with the latest cygwin update, it is failing. On a couple older 
machines, I do:
$ python -c "import ctypes; print ctypes._dlopen('cygwin1')"; cygcheck 
-V; python -V
6442713088
cygcheck (cygwin) 2.1.0
System Checker for Cygwin ...<snip>
Python 2.7.10
$ python -c "import ctypes; print ctypes._dlopen('cygwin1')"; cygcheck 
-V; python -V
6442713088
cygcheck (cygwin) 2.5.1
System Checker for Cygwin ...<snip>
Python 2.7.10
This last was on a windows 8.1 (Windows 8.1 Enterprise Ver 6.3 Build 
9600) system. I updated cygwin completely on that system to cygwin 
latest from a mirror. And, then
$ python -c "import ctypes; print ctypes._dlopen('cygwin1')"; cygcheck 
-V; python -V
Traceback (most recent call last):
 File "<string>", line 1, in <module>
OSError: No such file or directory
cygcheck (cygwin) 2.5.2
System Checker for Cygwin ...<snip>
Python 2.7.10
Note that simply changing the call to explicitly append the dll 
extension works fine:
$ python -c "import ctypes; print ctypes._dlopen('cygwin1.dll')"
6442713088
But that won't work with the former attribute-style of loading the dll.
--
Problem reports: http://cygwin.com/problems.html
FAQ: http://cygwin.com/faq/
Documentation: http://cygwin.com/docs.html
Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple


More information about the Cygwin mailing list

AltStyle によって変換されたページ (->オリジナル) /