Matt Clarke added the comment:
It seems that any argument greater than 8 bytes is automatically converted
to a references. Thus, changing to using ctypes.POINTER works. For example:
callback_t = ctypes.CFUNCTYPE(None, ctypes.POINTER(myst_args))
Quite a simple solution in the end. Is it worth
Matt Clarke added the comment:
Hi Amaury.
They are both 12 bytes.
Matt
--
___
Python tracker
<http://bugs.python.org/issue17310>
___
___
Python-bugs-list mailin
Matt Clarke added the comment:
Hi Amaury.
I have tried removing pack and using /Zp1, but it makes no difference.
The size of callback_t and the one in C are 8 bytes.
Thanks,
Matt
On 13 March 2013 13:19, Amaury Forgeot d'Arc wrote:
>
> Amaury Forgeot d'Arc added the comment
New submission from Matt Clarke:
I have had an issue arise with ctypes callbacks with 64bit Python on Windows.
Note: everything works fine with 32bit Python on Windows and on 32bit and 64bit
Linux.
I have created a simple example to illustrate the issue I have (see
attachment), but the real