search for: virconngetlasterror

Displaying 3 results from an estimated 3 matches for "virconngetlasterror".

2015 Jun 11
2
Re: [PATCH 3/5] threads: Use thread-local storage for errors.
...ppears to have reset itself back to the default > error handler). I haven't yet worked out a better way to solve this. Do you have a feeling whether the error handler function push/pop is a commonly used feature or not ? In libvirt we originally had virGetLastError (global error) virConnGetLastError (per connection error) virSetErrorFunc (global error handler func) When we introduced thread support we didn't try to make the virConnGetLastError/SetErrorFun work. We just updated the docs to tell applications to /never/ use them in threaded applications, and always use the virGetLastEr...
2015 Jun 11
0
Re: [PATCH 3/5] threads: Use thread-local storage for errors.
...; is a commonly used feature or not ? All the time, in our code: $ git grep -E 'guestfs_(push|pop)_error_handler' -- *.c | wc -l 83 Of course we could change those, but it is still an API guarantee. > In libvirt we originally had > > virGetLastError (global error) > virConnGetLastError (per connection error) > virSetErrorFunc (global error handler func) > > When we introduced thread support we didn't try to make the > virConnGetLastError/SetErrorFun work. We just updated the docs > to tell applications to /never/ use them in threaded applications, > a...
2015 Jun 06
7
[PATCH 0/5] Add support for thread-safe handle.
This patch isn't ready to go upstream. In fact, I think we might do a quick 1.30 release soon, and save this patch, and also the extensive changes proposed for the test suite[1], to after 1.30. Currently it is not safe to use the same handle from multiple threads, unless you implement your own mutexes. See: http://libguestfs.org/guestfs.3.html#multiple-handles-and-multiple-threads These