From 2d58a9801973f9f30f720385b8deeca50c26a719 Mon Sep 17 00:00:00 2001 From: Morgan Deters Date: Wed, 26 Mar 2014 18:05:02 -0400 Subject: [PATCH] Fix an off-the-end string pointer bug (showed up only in some Win32 builds). --- src/theory/logic_info.cpp | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/theory/logic_info.cpp b/src/theory/logic_info.cpp index 525b129cf..a85044cec 100644 --- a/src/theory/logic_info.cpp +++ b/src/theory/logic_info.cpp @@ -153,7 +153,9 @@ void LogicInfo::setLogicString(std::string logicString) throw(IllegalArgumentExc enableTheory(THEORY_BOOL); const char* p = logicString.c_str(); - if(!strcmp(p, "QF_SAT") || *p == '\0') { + if(*p == '\0') { + // propositional logic only; we're done. + } else if(!strcmp(p, "QF_SAT")) { // propositional logic only; we're done. p += 6; } else if(!strcmp(p, "QF_ALL_SUPPORTED")) { -- 2.30.2