Author: Jonas Devlieghere
Date: 2025-01-16T13:48:23-08:00
New Revision: 96ef428953ed0f2a6c973709005fd17fd18318a1

URL: 
https://github.com/llvm/llvm-project/commit/96ef428953ed0f2a6c973709005fd17fd18318a1
DIFF: 
https://github.com/llvm/llvm-project/commit/96ef428953ed0f2a6c973709005fd17fd18318a1.diff

LOG: [lldb] Avoid calling raw_string_ostream::str() in LLDBAssert.cpp (NFC)

Revert to the state after d7796855b879 and use the underlying buffer
directly. I was still under the impression that was unsafe, so I did a
drive-by fix, which this commit reverts.

Added: 
    

Modified: 
    lldb/source/Utility/LLDBAssert.cpp

Removed: 
    


################################################################################
diff  --git a/lldb/source/Utility/LLDBAssert.cpp 
b/lldb/source/Utility/LLDBAssert.cpp
index 3a1874ac2a9dc4..d7adb52f95fa44 100644
--- a/lldb/source/Utility/LLDBAssert.cpp
+++ b/lldb/source/Utility/LLDBAssert.cpp
@@ -53,7 +53,7 @@ void _lldb_assert(bool expression, const char *expr_text, 
const char *func,
       llvm::formatv("Assertion failed: ({0}), function {1}, file {2}, line 
{3}",
                     expr_text, func, file, line)
           .str(),
-      backtrace.str(),
+      buffer,
       "Please file a bug report against lldb reporting this failure log, and "
       "as many details as possible");
 }


        
_______________________________________________
lldb-commits mailing list
lldb-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits

Reply via email to