aboutsummaryrefslogtreecommitdiff
path: root/lib/Analysis/DataStructure/Local.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'lib/Analysis/DataStructure/Local.cpp')
-rw-r--r--lib/Analysis/DataStructure/Local.cpp3
1 files changed, 2 insertions, 1 deletions
diff --git a/lib/Analysis/DataStructure/Local.cpp b/lib/Analysis/DataStructure/Local.cpp
index dea8e9f360..a313bd5c56 100644
--- a/lib/Analysis/DataStructure/Local.cpp
+++ b/lib/Analysis/DataStructure/Local.cpp
@@ -581,7 +581,8 @@ void GraphBuilder::visitCallSite(CallSite CS) {
// If this is freopen, merge the file descriptor passed in with the
// result.
- Result.mergeWith(getValueDest(**--CS.arg_end()));
+ if (F->getName() == "freopen")
+ Result.mergeWith(getValueDest(**--CS.arg_end()));
return;
} else if (F->getName() == "fclose" && CS.arg_end()-CS.arg_begin() ==1){