[Lldb-commits] [lldb] 2c38201 - [test] Fix typo in setting the wrong Context test field

Jordan Rupprecht via lldb-commits lldb-commits at lists.llvm.org
Tue Sep 6 19:01:11 PDT 2022


Author: Jordan Rupprecht
Date: 2022-09-06T18:59:03-07:00
New Revision: 2c38201b091a82ac89f5668706baceff37c07197

URL: https://github.com/llvm/llvm-project/commit/2c38201b091a82ac89f5668706baceff37c07197
DIFF: https://github.com/llvm/llvm-project/commit/2c38201b091a82ac89f5668706baceff37c07197.diff

LOG: [test] Fix typo in setting the wrong Context test field

This manifests as an msan error because we check the value of `es`, but it's actually uninitialized because we mistakenly set `ss` twice.

Added: 
    

Modified: 
    lldb/unittests/Process/minidump/RegisterContextMinidumpTest.cpp

Removed: 
    


################################################################################
diff  --git a/lldb/unittests/Process/minidump/RegisterContextMinidumpTest.cpp b/lldb/unittests/Process/minidump/RegisterContextMinidumpTest.cpp
index b7d25b2d4f07..0bacd882d8e8 100644
--- a/lldb/unittests/Process/minidump/RegisterContextMinidumpTest.cpp
+++ b/lldb/unittests/Process/minidump/RegisterContextMinidumpTest.cpp
@@ -109,7 +109,7 @@ TEST(RegisterContextMinidump, ConvertMinidumpContext_x86_64) {
   Context.gs = 0x9091;
   Context.ss = 0x9293;
   Context.ds = 0x9495;
-  Context.ss = 0x9697;
+  Context.es = 0x9697;
   llvm::ArrayRef<uint8_t> ContextRef(reinterpret_cast<uint8_t *>(&Context),
                                      sizeof(Context));
 


        


More information about the lldb-commits mailing list