From 172e336b12fa32a1737f66d77a3f2de86f9cc8e8 Mon Sep 17 00:00:00 2001 From: Chris Lattner Date: Fri, 16 Jan 2009 19:01:46 +0000 Subject: [PATCH] only notify callbacks if they exist. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@62334 91177308-0d34-0410-b5e6-96231b3b80d8 --- lib/Lex/Pragma.cpp | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/lib/Lex/Pragma.cpp b/lib/Lex/Pragma.cpp index 6087774353..667e4361a8 100644 --- a/lib/Lex/Pragma.cpp +++ b/lib/Lex/Pragma.cpp @@ -400,7 +400,8 @@ void Preprocessor::HandlePragmaComment(Token &Tok) { } // If the pragma is lexically sound, notify any interested PPCallbacks. - Callbacks->PragmaComment(CommentLoc, II, ArgumentString); + if (Callbacks) + Callbacks->PragmaComment(CommentLoc, II, ArgumentString); } -- 2.50.1