diff options
author | Daniel P. Berrange <berrange@redhat.com> | 2009-01-20 22:10:52 +0000 |
---|---|---|
committer | Daniel P. Berrange <berrange@redhat.com> | 2009-01-20 22:10:52 +0000 |
commit | d6d8338a07b39e19ef8243cbbea48617096bfba1 (patch) | |
tree | 61df26d7cda46c622778afe2e6d9ec4449194199 /libvir.py | |
parent | 92583135c8a6576176511c92154a8806873a0beb (diff) | |
download | libvirt-python-split-d6d8338a07b39e19ef8243cbbea48617096bfba1.tar.gz libvirt-python-split-d6d8338a07b39e19ef8243cbbea48617096bfba1.tar.xz libvirt-python-split-d6d8338a07b39e19ef8243cbbea48617096bfba1.zip |
Use global thread-local error for all python error reportingv0.6.0
Diffstat (limited to 'libvir.py')
-rw-r--r-- | libvir.py | 7 |
1 files changed, 3 insertions, 4 deletions
@@ -26,10 +26,9 @@ class libvirtError(Exception): elif vol is not None: conn = vol._conn - if conn is None: - err = virGetLastError() - else: - err = conn.virConnGetLastError() + # Never call virConnGetLastError(). + # virGetLastError() is now thread local + err = virGetLastError() if err is None: msg = defmsg else: |