Errors seen in LOGS/python-libasyncns-0.7.1-6.fc17

This is a summary of errors seen when compiling with an experimental static analysis tool

Raw build logs can be seen here

Reference count too low

Code paths in which the reference count of an object is left too low. This could lead to the object being deallocated too early, triggering segfaults when later accessed. Over repeated calls, these errors could accumulate, increasing the likelihood of a segfault.

asyncns.c asyncns_del_query ob_refcnt of '*query' is 1 too low

Reference leaks

Code paths in which the reference count of an object is left too high, leading to memory leaks

addrinfoquery.c AddrInfoQuery_get_done ob_refcnt of '*tu' is 1 too high

Segfaults within error-handling paths

Code paths in error-handling that will lead to a segmentatation fault (e.g. under low memory conditions)

asyncns.c Asyncns_getaddrinfo dereferencing NULL (q->query) at asyncns.c:134
asyncns.c Asyncns_new dereferencing NULL (self->asyncns) at asyncns.c:34
asyncns.c Asyncns_res_query dereferencing NULL (q->query) at asyncns.c:378

Returning (PyObject*)NULL without setting an exception

These messages are often false-positives: the analysis tool has no knowledge about internal API calls that can lead to an exception being set
addrinfoquery.c AddrInfoQuery_get_done returning (PyObject*)NULL without setting an exception