[Libguestfs] [hivex] Segfault for an integer value to node_set_value
Peter Wu
peter at lekensteyn.nl
Mon Aug 4 08:47:47 UTC 2014
Hi,
When an integer argument is passed as value, node_set_value
segfaults. Reproducer is at the end of this message
The backtrace points at hivex-py.c, function get_value. While obj
is non-NULL, `bytes = PyUnicode_AsUTF8String (obj);` returns NULL.
Kind regards,
Peter
https://lekensteyn.nl
#!/usr/bin/env python3
import hivex, sys
h = hivex.Hivex(sys.argv[1])
print(h)
val = {
'key': 'broken',
't': 4,
'value': 1234
}
print(val)
r = h.node_set_value(h.root(), val)
print(r)
More information about the Libguestfs
mailing list