[cfe-commits] r62334 - /cfe/trunk/lib/Lex/Pragma.cpp

Chris Lattner sabre at nondot.org
Fri Jan 16 11:01:46 PST 2009


Author: lattner
Date: Fri Jan 16 13:01:46 2009
New Revision: 62334

URL: http://llvm.org/viewvc/llvm-project?rev=62334&view=rev
Log:
only notify callbacks if they exist.

Modified:
    cfe/trunk/lib/Lex/Pragma.cpp

Modified: cfe/trunk/lib/Lex/Pragma.cpp
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/lib/Lex/Pragma.cpp?rev=62334&r1=62333&r2=62334&view=diff

==============================================================================
--- cfe/trunk/lib/Lex/Pragma.cpp (original)
+++ cfe/trunk/lib/Lex/Pragma.cpp Fri Jan 16 13:01:46 2009
@@ -400,7 +400,8 @@
   }
   
   // If the pragma is lexically sound, notify any interested PPCallbacks.
-  Callbacks->PragmaComment(CommentLoc, II, ArgumentString);
+  if (Callbacks)
+    Callbacks->PragmaComment(CommentLoc, II, ArgumentString);
 }
 
 





More information about the cfe-commits mailing list