[Lldb-commits] [lldb] r117700 - /lldb/trunk/source/Expression/ClangUserExpression.cpp

Johnny Chen johnny.chen at apple.com
Fri Oct 29 13:19:44 PDT 2010


Author: johnny
Date: Fri Oct 29 15:19:44 2010
New Revision: 117700

URL: http://llvm.org/viewvc/llvm-project?rev=117700&view=rev
Log:
ClangUserExpression ctor should not crash if given a null expr_prefix char*.

Modified:
    lldb/trunk/source/Expression/ClangUserExpression.cpp

Modified: lldb/trunk/source/Expression/ClangUserExpression.cpp
URL: http://llvm.org/viewvc/llvm-project/lldb/trunk/source/Expression/ClangUserExpression.cpp?rev=117700&r1=117699&r2=117700&view=diff
==============================================================================
--- lldb/trunk/source/Expression/ClangUserExpression.cpp (original)
+++ lldb/trunk/source/Expression/ClangUserExpression.cpp Fri Oct 29 15:19:44 2010
@@ -38,7 +38,7 @@
 ClangUserExpression::ClangUserExpression (const char *expr,
                                           const char *expr_prefix) :
     m_expr_text(expr),
-    m_expr_prefix(expr_prefix),
+    m_expr_prefix(expr_prefix ? expr_prefix : ""),
     m_transformed_text(),
     m_jit_addr(LLDB_INVALID_ADDRESS),
     m_cplusplus(false),
@@ -483,4 +483,4 @@
         result_valobj_sp.reset (new ValueObjectConstResult (error));
 
     return result_valobj_sp;
-}
\ No newline at end of file
+}





More information about the lldb-commits mailing list