From: miker Date: Sat, 8 Dec 2007 19:31:57 +0000 (+0000) Subject: arg ... add tracking in both "new" functions X-Git-Url: https://old-git.evergreen-ils.org/?a=commitdiff_plain;h=4d52aba1fe2cb323987deb815f94ccb63a26f4fc;p=working%2FOpenSRF.git arg ... add tracking in both "new" functions git-svn-id: svn://svn.open-ils.org/OpenSRF/trunk@1162 9efc2488-bf62-4759-914b-345cdb29e865 --- diff --git a/src/libopensrf/osrf_json_object.c b/src/libopensrf/osrf_json_object.c index c87d4c5..9dcd123 100644 --- a/src/libopensrf/osrf_json_object.c +++ b/src/libopensrf/osrf_json_object.c @@ -110,9 +110,12 @@ jsonObject* jsonNewObjectFmt(const char* data, ...) { if( freeObjList ) { o = (jsonObject*) freeObjList; freeObjList = freeObjList->next; - } - else + unusedObjRelease++; + currentListLen--; + } else { OSRF_MALLOC( o, sizeof(jsonObject) ); + mallocObjCreate++; + } o->size = 0; o->classname = NULL;