[issue11427] ctypes from_buffer no longer accepts bytes

Santoso Wijaya report at bugs.python.org
Wed Nov 9 20:07:25 CET 2011


Santoso Wijaya <santoso.wijaya at gmail.com> added the comment:

>From what I understand, even in 2.7 the exception is expected. The doc for `from_buffer` says:

> The source object must support the writeable buffer interface.

Is there any reason why `from_buffer_copy` cannot be used, instead? The latter only requires readable buffer interface.

----------

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


More information about the Python-bugs-list mailing list