generator: Fix return type on failure
generator: Fix return type on failure

to return a negative value instead of None for consistency.

Signed-off-by: Philipp Hahn <8cb7a2c205789112a9f61bc3102305826b6a8db1@univention.de>

libvirt/libvirt-python,libvirt/libvirt-python,libvirt/libvirt-python