[issue47001] deadlock in ctypes?

2022-03-14 Thread Rocco Matano
Rocco Matano added the comment: I forgot to say thank you. I would like to make up for that: Thank you, Eryk. -- ___ Python tracker ___

[issue47001] deadlock in ctypes?

2022-03-13 Thread Rocco Matano
Rocco Matano added the comment: @Eryk I think you hit the nail on the head with your recommendation to avoid ctypes.c_wchar_p (i.e. wintypes.LPWSTR) as the parameter type when dealing resource type/name strings. Of course ctypes automatic conversion from a C character pointer to a Python

[issue47001] deadlock in ctypes?

2022-03-13 Thread Eryk Sun
Eryk Sun added the comment: Pointers to resource type/name strings use the lower 16-bit range for integer identifiers such as RT_ICON (3) and RT_GROUP_ICON (14). C code checks for these cases using the IS_INTRESOURCE() macro. It's incorrect to use a simple C string pointer type such as

[issue47001] deadlock in ctypes?

2022-03-12 Thread Rocco Matano
New submission from Rocco Matano : When using ctypes under Windows, I have observed a baffling behavior which I am not sure if it is the result of a bug in ctypes, or is simply due to false expectations on my part. Environment: - Windows 10 Pro, 21H1, 19043.1586, x64 - Python versions 3.6