Skip to content

Commit b0c0a6c

Browse files
nmantheyNlightNFotis
authored andcommitted
minisat: fix Options.cc
CBMC compiles with more strict compiler warnings. To make the compiler happy, extend the MiniSat patch to fix the Option.cc file as well.
1 parent 1bfbdd7 commit b0c0a6c

File tree

1 file changed

+17
-0
lines changed

1 file changed

+17
-0
lines changed

scripts/minisat-2.2.1-patch

Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -179,6 +179,23 @@ index 2dba10f..7d2e83a 100644
179179
if (verbose){
180180
fprintf(stderr, "\n %s\n", description);
181181
fprintf(stderr, "\n");
182+
diff --git a/minisat/utils/Options.cc b/minisat/utils/Options.cc
183+
index 83c40e8..15bfca1 100644
184+
--- a/minisat/utils/Options.cc
185+
+++ b/minisat/utils/Options.cc
186+
@@ -43,10 +43,12 @@ void Minisat::parseOptions(int& argc, char** argv, bool strict)
187+
}
188+
189+
if (!parsed_ok)
190+
+ {
191+
if (strict && match(argv[i], "-"))
192+
fprintf(stderr, "ERROR! Unknown flag \"%s\". Use '--%shelp' for help.\n", argv[i], Option::getHelpPrefixString()), exit(1);
193+
else
194+
argv[j++] = argv[i];
195+
+ }
196+
}
197+
}
198+
182199
diff --git a/minisat/utils/ParseUtils.h b/minisat/utils/ParseUtils.h
183200
index d307164..7b46f09 100644
184201
--- a/minisat/utils/ParseUtils.h

0 commit comments

Comments
 (0)