Add two missing returns, which caused us to be very pessimistic about the
printf and scanf families!
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@11683 91177308-0d34-0410-b5e6-96231b3b80d8
diff --git a/lib/Analysis/DataStructure/Local.cpp b/lib/Analysis/DataStructure/Local.cpp
index a3a0e2e..88dd5a3 100644
--- a/lib/Analysis/DataStructure/Local.cpp
+++ b/lib/Analysis/DataStructure/Local.cpp
@@ -38,7 +38,6 @@
static cl::opt<bool>
TrackIntegersAsPointers("dsa-track-integers",
cl::desc("If this is set, track integers as potential pointers"));
-
namespace llvm {
namespace DS {
@@ -581,6 +580,7 @@
if (DSNode *N = getValueDest(**AI).getNode())
N->setReadMarker();
}
+ return;
} else if (F->getName() == "scanf" || F->getName() == "fscanf" ||
F->getName() == "sscanf") {
CallSite::arg_iterator AI = CS.arg_begin(), E = CS.arg_end();
@@ -612,6 +612,7 @@
if (DSNode *N = getValueDest(**AI).getNode())
N->setModifiedMarker();
}
+ return;
} else if (F->getName() == "strtok") {
// strtok reads and writes the first argument, returning it. It reads
// its second arg. FIXME: strtok also modifies some hidden static