diff options
author | gordana.cmiljanovic@imgtec.com <gordana.cmiljanovic@imgtec.com@4c0a9323-5329-0410-9bdc-e9ce6186880e> | 2014-05-14 09:11:35 +0000 |
---|---|---|
committer | gordana.cmiljanovic@imgtec.com <gordana.cmiljanovic@imgtec.com@4c0a9323-5329-0410-9bdc-e9ce6186880e> | 2014-05-14 09:11:35 +0000 |
commit | 412b68396c562b4a8ec098be37baeb2c70bfe976 (patch) | |
tree | e2ef9fe7fee6e74caf18a8f2e3d3a902e91152d3 /src/client/linux/minidump_writer | |
parent | [Mac] Remove unused host_info call and supporting calls. (diff) | |
download | breakpad-412b68396c562b4a8ec098be37baeb2c70bfe976.tar.xz |
[MIPS] Fix core dump related unit tests for Android on MIPS
This change fixes failing unittests in Android on MIPS:
LinuxCoreDumperTest.VerifyDumpWithMultipleThreads
ElfCoreDumpTest.ValidCoreFile
BUG=None
TEST=Running breakpad_unittests on MIPS Android device
Review URL: https://breakpad.appspot.com/3664002
git-svn-id: http://google-breakpad.googlecode.com/svn/trunk@1330 4c0a9323-5329-0410-9bdc-e9ce6186880e
Diffstat (limited to 'src/client/linux/minidump_writer')
-rw-r--r-- | src/client/linux/minidump_writer/linux_core_dumper.cc | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/src/client/linux/minidump_writer/linux_core_dumper.cc b/src/client/linux/minidump_writer/linux_core_dumper.cc index eb9e3fd0..aa6aa70f 100644 --- a/src/client/linux/minidump_writer/linux_core_dumper.cc +++ b/src/client/linux/minidump_writer/linux_core_dumper.cc @@ -188,7 +188,19 @@ bool LinuxCoreDumper::EnumerateThreads() { memset(&info, 0, sizeof(ThreadInfo)); info.tgid = status->pr_pgrp; info.ppid = status->pr_ppid; +#if defined(__mips__) + for (int i = EF_REG0; i <= EF_REG31; i++) + info.regs.regs[i - EF_REG0] = status->pr_reg[i]; + + info.regs.lo = status->pr_reg[EF_LO]; + info.regs.hi = status->pr_reg[EF_HI]; + info.regs.epc = status->pr_reg[EF_CP0_EPC]; + info.regs.badvaddr = status->pr_reg[EF_CP0_BADVADDR]; + info.regs.status = status->pr_reg[EF_CP0_STATUS]; + info.regs.cause = status->pr_reg[EF_CP0_CAUSE]; +#else memcpy(&info.regs, status->pr_reg, sizeof(info.regs)); +#endif if (first_thread) { crash_thread_ = pid; crash_signal_ = status->pr_info.si_signo; |