[issue4376] Nested ctypes 'BigEndianStructure' fails

STINNER Victor report at bugs.python.org
Wed Jul 13 18:26:27 CEST 2011


STINNER Victor <victor.stinner at haypocalc.com> added the comment:

> But if you set raw memory to let's say b'\0\0\0\1',
> when you look at the c_int value afterwards, won't it
> be different on little endian and big endian machines?

A big endian structure is supposed to read and write memory in the... big endian order, not in the host endian.

----------

_______________________________________
Python tracker <report at bugs.python.org>
<http://bugs.python.org/issue4376>
_______________________________________


More information about the Python-bugs-list mailing list