Index: lldb/trunk/source/Plugins/MemoryHistory/asan/MemoryHistoryASan.cpp =================================================================== --- lldb/trunk/source/Plugins/MemoryHistory/asan/MemoryHistoryASan.cpp +++ lldb/trunk/source/Plugins/MemoryHistory/asan/MemoryHistoryASan.cpp @@ -176,8 +176,8 @@ HistoryThreads result; - CreateHistoryThreadFromValueObject(process_sp, return_value_sp, "alloc", "Memory allocated at", result); CreateHistoryThreadFromValueObject(process_sp, return_value_sp, "free", "Memory deallocated at", result); + CreateHistoryThreadFromValueObject(process_sp, return_value_sp, "alloc", "Memory allocated at", result); return result; } Index: lldb/trunk/test/functionalities/asan/TestMemoryHistory.py =================================================================== --- lldb/trunk/test/functionalities/asan/TestMemoryHistory.py +++ lldb/trunk/test/functionalities/asan/TestMemoryHistory.py @@ -86,18 +86,18 @@ history_thread = threads.GetThreadAtIndex(0) self.assertTrue(history_thread.num_frames >= 2) self.assertEqual(history_thread.frames[1].GetLineEntry().GetFileSpec().GetFilename(), "main.c") - self.assertEqual(history_thread.frames[1].GetLineEntry().GetLine(), self.line_malloc) + self.assertEqual(history_thread.frames[1].GetLineEntry().GetLine(), self.line_free) history_thread = threads.GetThreadAtIndex(1) self.assertTrue(history_thread.num_frames >= 2) self.assertEqual(history_thread.frames[1].GetLineEntry().GetFileSpec().GetFilename(), "main.c") - self.assertEqual(history_thread.frames[1].GetLineEntry().GetLine(), self.line_free) + self.assertEqual(history_thread.frames[1].GetLineEntry().GetLine(), self.line_malloc) # let's free the container (SBThreadCollection) and see if the SBThreads still live threads = None self.assertTrue(history_thread.num_frames >= 2) self.assertEqual(history_thread.frames[1].GetLineEntry().GetFileSpec().GetFilename(), "main.c") - self.assertEqual(history_thread.frames[1].GetLineEntry().GetLine(), self.line_free) + self.assertEqual(history_thread.frames[1].GetLineEntry().GetLine(), self.line_malloc) # now let's break when an ASan report occurs and try the API then self.runCmd("breakpoint set -n __asan_report_error")