[cfe-commits] r111447 - /cfe/trunk/lib/Rewrite/HTMLRewrite.cpp

Douglas Gregor dgregor at apple.com
Wed Aug 18 16:03:13 PDT 2010


Author: dgregor
Date: Wed Aug 18 18:03:13 2010
New Revision: 111447

URL: http://llvm.org/viewvc/llvm-project?rev=111447&view=rev
Log:
Fix crasher with IgnoringDiagClient

Modified:
    cfe/trunk/lib/Rewrite/HTMLRewrite.cpp

Modified: cfe/trunk/lib/Rewrite/HTMLRewrite.cpp
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/lib/Rewrite/HTMLRewrite.cpp?rev=111447&r1=111446&r2=111447&view=diff
==============================================================================
--- cfe/trunk/lib/Rewrite/HTMLRewrite.cpp (original)
+++ cfe/trunk/lib/Rewrite/HTMLRewrite.cpp Wed Aug 18 18:03:13 2010
@@ -486,8 +486,7 @@
 
   // Temporarily change the diagnostics object so that we ignore any generated
   // diagnostics from this pass.
-  IgnoringDiagClient TmpDC;
-  Diagnostic TmpDiags(&TmpDC);
+  Diagnostic TmpDiags(new IgnoringDiagClient);
 
   // FIXME: This is a huge hack; we reuse the input preprocessor because we want
   // its state, but we aren't actually changing it (we hope). This should really





More information about the cfe-commits mailing list