Bug fix
[satune.git] / src / Backend / cnfexpr.cc
index 1aa6cf0abc09d388cb89481b5b5cc822969d7f22..b04044ad914fef1b31ac4264bc7faedab9bed8ff 100644 (file)
@@ -169,6 +169,7 @@ void copyCNF(CNFExpr *This, CNFExpr *expr, bool destroy) {
                ourfree(This->singletons.literals);
                ourfree(This->clauses.array);
                This->litSize = expr->litSize;
+               This->singletons.size = expr->singletons.size;
                This->singletons.literals = expr->singletons.literals;
                This->singletons.capacity = expr->singletons.capacity;
                This->clauses.size = expr->clauses.size;
@@ -190,7 +191,7 @@ void copyCNF(CNFExpr *This, CNFExpr *expr, bool destroy) {
 
 void conjoinCNFExpr(CNFExpr *This, CNFExpr *expr, bool destroy) {
        if (expr->litSize == 0) {
-               if (!This->isTrue) {
+               if (!expr->isTrue) {
                        clearCNFExpr(This, false);
                }
                if (destroy) {