diff options
Diffstat (limited to 'src/dataconnect.c')
-rw-r--r-- | src/dataconnect.c | 8 |
1 files changed, 3 insertions, 5 deletions
diff --git a/src/dataconnect.c b/src/dataconnect.c index 8dacdcc..110e369 100644 --- a/src/dataconnect.c +++ b/src/dataconnect.c @@ -93,6 +93,7 @@ char* portageBestVersion(StringList *pkgs) } char *ret = pyStringToString(obj); + Py_DECREF(obj); return ret; @@ -112,10 +113,7 @@ char* portageGetBestEbuild(const char *pkg) } char *ret = pyStringToString(obj); - //PyObject *tmp = PyUnicode_AsUTF8String(obj); - //char *ret = strdup(PyString_AsString(tmp)); - - //Py_DECREF(tmp); + Py_DECREF(obj); return ret; @@ -362,7 +360,7 @@ StringList* portageGetUnresolvedPkgs() StringList* portageGetAllNodes() { - PyObject *obj = executeFunction("portage.api.data_connect", "get_all_nodes", NULL); + PyObject *obj = executeFunction("portage.api.data_connect", "get_allnodes", NULL); if (!obj || !PySequence_Check(obj)) { if (obj) |