* python/libvir.c: fixed a bug in the new wrapper
[libvirt-python/ericb.git] / libvir.py
blob29dc8c41dea39ec762c97c4ecfccb651522d1e22
1 #!/usr/bin/python -u
3 # Those are the autogenerated Python bindings for libvirt.
4 # Check python/generator.py in the source distribution of libvir
5 # to find out more about the generation process
7 import libvirtmod
8 import types
10 # The root of all libxml2 errors.
11 class libvirtError(Exception):
12 pass
16 # register the libvirt global error handler
18 def registerErrorHandler(f, ctx):
19 """Register a Python written function to for error reporting.
20 The function is called back as f(ctx, error), with error
21 being a list of informations about the error being raised.
22 Returns 1 in case of success."""
23 return libvirtmod.virRegisterErrorHandler(f,ctx)
25 # WARNING WARNING WARNING WARNING WARNING WARNING WARNING WARNING WARNING
27 # Everything before this line comes from libvir.py
28 # Everything after this line is automatically generated
30 # WARNING WARNING WARNING WARNING WARNING WARNING WARNING WARNING WARNING