On Saturday, 6 May 2017 11:32:26 CEST Matteo Cafasso wrote:
This series addresses the issue where non UTF8 file names in a guest
image lead to libguestfs segfault with Python 3 APIs.
All the patches are basically parts of the same fix, so I'd squash them
together in a single patch that changes the generator, the manual
parts, and add a test to prove the fix works.
The core issue is the APIs are not checking the return value when
constructing a new PyObject. Therefore NULL pointers are added to
Python collections (lists and dictionaries) crashing the application.
All these #ifdef HAVE_PYSTRING_ASSTRING blocks make both the OCaml, and
the generated C code hard to read -- I've just send a cleanup patch for
this:
https://www.redhat.com/archives/libguestfs/2017-May/msg00051.html
Aside this, and the notes left for patch #3, the changes would look
correct to me.
Thanks,
--
Pino Toscano