From 1500c419664a0f8387f776d66ecc0b0051e44ce9 Mon Sep 17 00:00:00 2001 From: "mkrebs@chromium.org" Date: Mon, 8 Oct 2012 20:33:06 +0000 Subject: Don't bail if a thread's stack pointer is invalid Currently, if a thread's stack pointer is not within a valid memory page, the minidump writing will fail with an error. This change allows an invalid stack pointer by simply setting the memory size to zero in the minidump. The processing code already checks for the size being zero, although it currently just gives an error (see https://breakpad.appspot.com/413002/). BUG=google-breakpad:499, chromium-os:34880 TEST=make check, manually ran minidump-2-core and core2md Review URL: https://breakpad.appspot.com/478002 git-svn-id: http://google-breakpad.googlecode.com/svn/trunk@1065 4c0a9323-5329-0410-9bdc-e9ce6186880e --- src/client/linux/minidump_writer/linux_core_dumper_unittest.cc | 3 +++ 1 file changed, 3 insertions(+) (limited to 'src/client/linux/minidump_writer/linux_core_dumper_unittest.cc') diff --git a/src/client/linux/minidump_writer/linux_core_dumper_unittest.cc b/src/client/linux/minidump_writer/linux_core_dumper_unittest.cc index d04ef3e1..50b31938 100644 --- a/src/client/linux/minidump_writer/linux_core_dumper_unittest.cc +++ b/src/client/linux/minidump_writer/linux_core_dumper_unittest.cc @@ -105,6 +105,9 @@ TEST(LinuxCoreDumperTest, VerifyDumpWithMultipleThreads) { for (unsigned i = 0; i < kNumOfThreads; ++i) { ThreadInfo info; EXPECT_TRUE(dumper.GetThreadInfoByIndex(i, &info)); + const void* stack; + size_t stack_len; + EXPECT_TRUE(dumper.GetStackInfo(&stack, &stack_len, info.stack_pointer)); EXPECT_EQ(getpid(), info.ppid); } } -- cgit v1.2.1