Fix delete function
authorbdemsky <bdemsky@uci.edu>
Tue, 20 Jun 2017 01:59:33 +0000 (18:59 -0700)
committerbdemsky <bdemsky@uci.edu>
Tue, 20 Jun 2017 01:59:33 +0000 (18:59 -0700)
src/csolver.c

index 7a9d1e0d2870ce3c87d4adf828fc9665655af3a4..a7af8d304d1a66bcb3029967d992f6a0294a46ea 100644 (file)
@@ -30,33 +30,38 @@ void deleteSolver(CSolver *This) {
        for(uint i=0;i<size;i++) {
                deleteBoolean(getVectorBoolean(This->allBooleans, i));
        }
-
        deleteVectorBoolean(This->allBooleans);
 
        size=getSizeVectorSet(This->allSets);
        for(uint i=0;i<size;i++) {
                deleteSet(getVectorSet(This->allSets, i));
        }
-
        deleteVectorSet(This->allSets);
 
        size=getSizeVectorElement(This->allElements);
        for(uint i=0;i<size;i++) {
                deleteElement(getVectorElement(This->allElements, i));
        }
+       deleteVectorElement(This->allElements);
+
        size=getSizeVectorTable(This->allTables);
        for(uint i=0;i<size;i++) {
                deleteTable(getVectorTable(This->allTables, i));
        }
+       deleteVectorTable(This->allTables);
+       
        size=getSizeVectorPredicate(This->allPredicates);
        for(uint i=0;i<size;i++) {
                deletePredicate(getVectorPredicate(This->allPredicates, i));
        }
+       deleteVectorPredicate(This->allPredicates);
+
        size=getSizeVectorOrder(This->allOrders);
        for(uint i=0;i<size;i++) {
                deleteOrder(getVectorOrder(This->allOrders, i));
        }
        deleteVectorOrder(This->allOrders);
+       
        size=getSizeVectorFunction(This->allFunctions);
        for(uint i=0;i<size;i++) {
                deleteFunction(getVectorFunction(This->allFunctions, i));