Patch from Scott McKellar to plug a memory leak in the mathbench test application
authormiker <miker@9efc2488-bf62-4759-914b-345cdb29e865>
Thu, 31 Jan 2008 19:31:07 +0000 (19:31 +0000)
committermiker <miker@9efc2488-bf62-4759-914b-345cdb29e865>
Thu, 31 Jan 2008 19:31:07 +0000 (19:31 +0000)
git-svn-id: svn://svn.open-ils.org/OpenSRF/trunk@1241 9efc2488-bf62-4759-914b-345cdb29e865

src/c-apps/osrf_math.c

index f2e614d..7818451 100644 (file)
@@ -100,6 +100,10 @@ int osrfMathRun( osrfMethodContext* ctx ) {
 
                        osrfAppSessionFree(ses);
                }
+               else {
+                       if(a) free(a);
+                       if(b) free(b);
+               }
        }
 
        return -1;