[llvm-branch-commits] [cfe-tag] r90061 - /cfe/tags/checker/checker-228/lib/Analysis/UndefResultChecker.cpp

Ted Kremenek kremenek at apple.com
Sat Nov 28 22:41:52 PST 2009


Author: kremenek
Date: Sun Nov 29 00:41:52 2009
New Revision: 90061

URL: http://llvm.org/viewvc/llvm-project?rev=90061&view=rev
Log:
Merge in 90060.

Modified:
    cfe/tags/checker/checker-228/lib/Analysis/UndefResultChecker.cpp

Modified: cfe/tags/checker/checker-228/lib/Analysis/UndefResultChecker.cpp
URL: http://llvm.org/viewvc/llvm-project/cfe/tags/checker/checker-228/lib/Analysis/UndefResultChecker.cpp?rev=90061&r1=90060&r2=90061&view=diff

==============================================================================
--- cfe/tags/checker/checker-228/lib/Analysis/UndefResultChecker.cpp (original)
+++ cfe/tags/checker/checker-228/lib/Analysis/UndefResultChecker.cpp Sun Nov 29 00:41:52 2009
@@ -20,7 +20,7 @@
 using namespace clang;
 
 namespace {
-class VISIBILITY_HIDDEN UndefResultChecker 
+class UndefResultChecker 
   : public CheckerVisitor<UndefResultChecker> {
 
   BugType *BT;
@@ -76,9 +76,10 @@
     }
     EnhancedBugReport *report = new EnhancedBugReport(*BT, 
                                                     OS.str().str().c_str(), N);
-    report->addRange(Ex->getSourceRange());
-    if (Ex)
+    if (Ex) {
+      report->addRange(Ex->getSourceRange());
       report->addVisitorCreator(bugreporter::registerTrackNullOrUndefValue, Ex);
+    }
     else
       report->addVisitorCreator(bugreporter::registerTrackNullOrUndefValue, B);
     C.EmitReport(report);





More information about the llvm-branch-commits mailing list