From 960534c86652caa52e18beb1dcb00c3e58d4cb72 Mon Sep 17 00:00:00 2001 From: Sean Callanan Date: Wed, 21 Dec 2011 23:44:05 +0000 Subject: [PATCH] Made IRForTarget error out correctly when it can't complete the result type, preventing crashes later. llvm-svn: 147107 --- lldb/source/Expression/IRForTarget.cpp | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/lldb/source/Expression/IRForTarget.cpp b/lldb/source/Expression/IRForTarget.cpp index 258953ac5975..2c0d8ba80fa3 100644 --- a/lldb/source/Expression/IRForTarget.cpp +++ b/lldb/source/Expression/IRForTarget.cpp @@ -675,8 +675,9 @@ IRForTarget::CreateResultVariable (llvm::Function &llvm_function) log->Printf("Result type has size 0"); if (m_error_stream) - m_error_stream->Printf("Internal error [IRForTarget]: Result type '%s' has invalid size\n", + m_error_stream->Printf("Error [IRForTarget]: Size of result type '%s' couldn't be determined\n", type_desc_stream.GetData()); + return false; } if (log)