aboutsummaryrefslogtreecommitdiff
path: root/src/client/linux/minidump_writer/minidump_writer.cc
Commit message (Collapse)AuthorAgeFilesLines
* fix pointer style to match the style guideMike Frysinger2020-07-151-4/+4
| | | | | | | | | | We do this in a lot of places, but we're inconsistent. Normalize the code to the Google C++ style guide. Change-Id: Ic2aceab661ce8f6b993dda21b1cdf5d2198dcbbf Reviewed-on: https://chromium-review.googlesource.com/c/breakpad/breakpad/+/2262932 Reviewed-by: Sterling Augustine <saugustine@google.com> Reviewed-by: Mark Mentovai <mark@chromium.org>
* Linux MinidumpWriter: fix stack-use-after-scope violationMark Mentovai2019-04-261-2/+4
| | | | | | | | | | | | | | | | | | One form of google_breakpad::WriteMinidump() passed MappingList and AppMemoryList objects by reference to a MinidumpWriter object, instantiating them directly as constructor parameters. The MinidumpWriter stored these objects internally as references, and the underlying objects went out of scope after MinidumpWriter construction. The MinidumpWriter outlived them, causing a violation on any attempt to access them following construction. This bug was detected by AddressSanitizer at https://logs.chromium.org/logs/chromium/buildbucket/cr-buildbucket.appspot.com/8915150848087289472/+/steps/breakpad_unittests__with_patch_/0/stdout Bug: chromium:949098 Change-Id: I072ea9f1b64e1eae3e89d4a2b158764ff7970db5 Reviewed-on: https://chromium-review.googlesource.com/c/breakpad/breakpad/+/1585946 Reviewed-by: Robert Sesek <rsesek@chromium.org>
* linux_core_dumper: support setting exception_informationMike Frysinger2019-03-121-0/+6
| | | | | | | | | | | | | | Many signals in Linux support additional metadata on a per-signal basis. We can extract that from NT_SIGINFO and pass it through in the exception_information fields. The current core dumper logic doesn't set exception_information at all, so this is an improvement. Bug: google-breakpad:791 Change-Id: I38b78d6494e9bc682441750d98ac9be5b0656f5a Reviewed-on: https://chromium-review.googlesource.com/c/breakpad/breakpad/+/1497662 Reviewed-by: Mark Mentovai <mark@chromium.org>
* Rename MDRawContextARM64 and its context flagsJoshua Peraza2018-08-011-1/+1
| | | | | | | | | | This makes way for the addition of a struct matching Microsoft's layout for ARM64. Change-Id: I115f25290863e7438852691d1ec3c9324a42f7a5 Reviewed-on: https://chromium-review.googlesource.com/1152158 Reviewed-by: Mark Mentovai <mark@chromium.org> Reviewed-by: Mike Frysinger <vapier@chromium.org>
* Linux: Write out si_code for SIGBUS exceptions.Lei Zhang2018-04-031-8/+9
| | | | | | | | | Store the information in the exception record's exception_information field. Change-Id: Ie215cae2f070fdab63c3d05cc1bc4fb4b7b095fa Reviewed-on: https://chromium-review.googlesource.com/990799 Reviewed-by: Mark Mentovai <mark@chromium.org>
* Replace remaining references to 'struct ucontext' with 'ucontext_t'Mark Mentovai2017-09-201-1/+1
| | | | | | | | | | | | | | | | | This relands https://chromium.googlesource.com/breakpad/breakpad/src/+/e3035bc406cee8a4d765e59ad46eb828705f17f4, which was accidentally committed to breakpad/breakpad/src, the read-only mirror of src in breakpad/breakpad. (Well, it should have been read-only.) See https://crbug.com/766164. This fixes issues with glibc-2.26. See https://bugs.gentoo.org/show_bug.cgi?id=628782 , https://sourceware.org/git/?p=glibc.git;h=251287734e89a52da3db682a8241eb6bccc050c9 , and https://sourceware.org/ml/libc-alpha/2017-08/msg00010.html for context. Change-Id: Id66f474d636dd2afa450bab925c5514a800fdd6f Reviewed-on: https://chromium-review.googlesource.com/674304 Reviewed-by: Mark Mentovai <mark@chromium.org>
* Don't generate minidump if crash thread doesn't ref principal mapping.Tobias Sargeant2017-03-231-7/+49
| | | | | | | | | | | | | If the crashing thread doesn't reference the principal mapping we can assume that not only is that thread uninteresting from a debugging perspective, the whole crash is uninteresting. In that case we should not generate a minidump at all. BUG=703599 Change-Id: Ia25bbb8adb79d04dcaf3992c3d2474f3b9b1f796 Reviewed-on: https://chromium-review.googlesource.com/457338 Reviewed-by: Robert Sesek <rsesek@chromium.org>
* Use the correct PC when determining whether to skip storing a stack.Tobias Sargeant2017-02-231-5/+7
| | | | | | | | | | | | This addresses a bug in commit 049a1532 that meant that the PC of the crashing thread was always used to determine whether to include a stack, instead of using the PC of the thread in question. BUG=664460 Change-Id: Idcbd5db751e5c00941a1be28607389961c0c75d7 Reviewed-on: https://chromium-review.googlesource.com/446499 Reviewed-by: Robert Sesek <rsesek@chromium.org>
* Wire up stack sanitization and skipping to WriteMinidumpTobias Sargeant2017-02-031-26/+105
| | | | | | | | | | | | This makes the parameters stored in the MinidumpDescriptor structure functional for minidumps, analogously to how they are applied to microdumps. BUG=664460 Change-Id: I7578e7a1638cea8f0445b18d4bbdaf5e0a32d808 Reviewed-on: https://chromium-review.googlesource.com/435380 Reviewed-by: Robert Sesek <rsesek@chromium.org>
* Fix stack collection with size limitLars Volker2016-05-241-0/+8
| | | | | | | | | | | | | | | | | | | | | | | | | | | | src/client/linux/minidump_writer/minidump_writer.cc:273 obtains the stack info by calling GetStackInfo(). That method will return the stack base address, aligned to the bottom of the memory page that 'stack_pointer' is in. After that it will cap the size of the memory area to be copied into the minidump to 'max_stack_len', starting from the base address, if the caller requested so. This will be the case when collecting reduced stacks, as introduced by this change: https://breakpad.appspot.com/487002/ In such cases the caller will request 2048 bytes of memory. However GetStackInfo() will have aligned the base address to the page boundary, by default 4096 bytes. If the stack, which grows towards the base address from the top ends before the 2048 bytes of the first block, then we will not collect any useful part of the stack. As a fix we skip chunks of 'max_stack_len' bytes starting from the base address until the stack_pointer is actually contained in the chunk, which we will add to the minidump file. BUG=https://bugs.chromium.org/p/google-breakpad/issues/detail?id=695 R=ivanpe@chromium.org Review URL: https://codereview.chromium.org/1959643004 . Patch from Lars Volker <lv@cloudera.com>.
* Switch the Linux minidump writer to use MDCVInfoELF for CV data.Ted Mielczarek2016-04-051-23/+25
| | | | | | | | | | | | | | | | | | | | | | | | | | This preserves full build ids in minidumps, which are useful for tracking down the right version of system libraries from Linux distributions. The default build id produced by GNU binutils' ld is a 160-bit SHA-1 hash of some parts of the binary, which is exactly 20 bytes: https://sourceware.org/binutils/docs-2.26/ld/Options.html#index-g_t_002d_002dbuild_002did-292 The bulk of the changes here are to change the signatures of the FileID methods to use a wasteful_vector instead of raw pointers, since build ids can be of arbitrary length. The previous change that added support for this in the processor code preserved the return value of `Minidump::debug_identifier()` as the current `GUID+age` treatment for backwards-compatibility, and exposed the full build id from `Minidump::code_identifier()`, which was previously stubbed out for Linux dumps. This change keeps the debug ID in the `dump_syms` output the same to match. R=mark@chromium.org, thestig@chromium.org BUG= Review URL: https://codereview.chromium.org/1688743002 .
* Add an optional root prefix to Linux dumpersDominik Laskowski2016-03-071-1/+1
| | | | | | | | | | | The Linux dumpers use absolute paths for shared libraries referenced by dumps, so they fail to locate them if the crash originated in a chroot. This CL enables callers to specify a root prefix, which is prepended to mapping paths before opening them. BUG=chromium:591792 TEST=make check Review URL: https://codereview.chromium.org/1761023002/
* Ensure Linux minidump writer flushes minidump header early.Ted Mielczarek2016-02-121-11/+18
| | | | | | | | | | | | | | | | If the Linux minidump writer crashes while writing a dump, the dump might contain some useful information, but the header will be empty because TypedMDRVA's destructor flushes the data, and the header var doesn't go out of scope until the end of the `Dump` method. This fixes that problem by putting the header in a shorter block scope. We've seen this problem in some Android dumps in the wild, like: https://crash-stats.mozilla.com/report/index/cef5b777-02d1-43c2-bf40-133ab2160209 R=thestig@chromium.org BUG=https://bugzilla.mozilla.org/show_bug.cgi?id=1247978 Review URL: https://codereview.chromium.org/1696573003 .
* [mips64] Support for mips n64Mike Frysinger2016-02-061-0/+6
| | | | | | | | | | Adding remaining mips n64 support including stackwalker. BUG=None TEST=manually tested on Linux/Android R=vapier@chromium.org Review URL: https://codereview.chromium.org/1418453011 .
* Fix compilation of breakpad on Linux.Sylvain Defresne2016-01-081-2/+2
| | | | | | | | | Fix some copy/paste errors from commit 41440eaa. BUG=None R=thestig@chromium.org Review URL: https://codereview.chromium.org/1564293002 .
* Use range-based for loops in linux/minidump_writer/minidump_writer.cc.Lei Zhang2016-01-071-45/+32
| | | | | | | | Also fix lint errors. R=mark@chromium.org Review URL: https://codereview.chromium.org/1562273002 .
* Avoid comparing size_t to be < 0 on AArch64.Lei Zhang2016-01-061-2/+2
| | | | | | | | | | | | cpu_features_entries is empty on AArch64 and causes tautological-compare warning when compiling with Clang. A=dskiba@google.com Original Review: https://codereview.chromium.org/1562223002/ BUG=chromium:539781 Review URL: https://codereview.chromium.org/1566893002 .
* Remove obsolete seccomp_unwinder for legacy (pre-BPF) sandboxprimiano@chromium.org2015-08-181-6/+0
| | | | | | | | | | | | | | | | | | | | | The PopSeccompStackFrame was introduced to deal with stack frames originated in the legacy seccomp sandbox. The only user of that sandbox was Google Chrome, but the legacy sandbox has been deprecated in 2013 (crrev.com/1290643003) in favor of the new bpf sandbox. Removing this dead code as it has some small bound checking bug which causes occasional crashes in WebView (which are totally unrelated to the sandbox). Note: this will require a corresponding change in the chromium GYP/GN build files to roll. BUG=665,chromium:477444 R=jln@chromium.org, mark@chromium.org, torne@chromium.org Review URL: https://codereview.chromium.org/1299593003 . git-svn-id: http://google-breakpad.googlecode.com/svn/trunk@1492 4c0a9323-5329-0410-9bdc-e9ce6186880e
* Update breakpad for Android packed relocations.rmcilroy@chromium.org2015-06-191-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | Shared libraries containing Android packed relocations have a load bias that differs from the start address in /proc/$$/maps. Current breakpad assumes that the load bias and mapping start address are the same. Fixed by changing the client to detect the presence of Android packed relocations in the address space of a loaded library, and adjusting the stored mapping start address of any that are packed so that it contains the linker's load bias. For this to work properly, it is important that the non-packed library is symbolized for breakpad. Either packed or non-packed libraries may be run on the device; the client detects which has been loaded by the linker. BUG=499747 R=primiano@chromium.org, rmcilroy@chromium.org Review URL: https://codereview.chromium.org/1189823002. Patch from Simon Baldwin <simonb@chromium.org>. git-svn-id: http://google-breakpad.googlecode.com/svn/trunk@1459 4c0a9323-5329-0410-9bdc-e9ce6186880e
* MIPS64: Initial MIPS64 related change.mark@chromium.org2015-04-151-1/+9
| | | | | | | | | | | With this change Breakpad can be compiled for MIPS64, but it is not yet functional. Patch by Gordana Cmiljanovic <Gordana.Cmiljanovic@imgtec.com> Review URL: https://breakpad.appspot.com/6824002/ git-svn-id: http://google-breakpad.googlecode.com/svn/trunk@1446 4c0a9323-5329-0410-9bdc-e9ce6186880e
* Handle failures of copying process data from a core file.benchan@chromium.org2015-02-021-8/+19
| | | | | | | | | | | | | | | | | | | | | | | | | When LinuxCoreDumper fails to copy process data from a core file, it fills the return buffer with a repeated sequence of a special marker. However, MinidumpWriter doesn't know about that and may incorrectly interpret the data. In many cases, MinidumpWriter simply copies the gibberish data to the minidump, which isn't too bad. However, the gibberish data may cause MinidumpWriter to behave badly in some other cases. For example, when MinidumpWriter tries to iterate through the linked list of all loaded DSOs via the r_map field of a r_debug struct, if the linked list is filed with the special marker, the code keeps iterating through the same address. This CL addresses the issue by having LinuxCoreDumper::CopyFromProcess() returns a Boolean value to indicate if the expected data is found from the core file. MinidumpWriter can then decide how to handle that. BUG=chromium:453484 TEST=Run core2md with the test data attached to chromium:453484. R=mark@chromium.org Review URL: https://breakpad.appspot.com/4724002 git-svn-id: http://google-breakpad.googlecode.com/svn/trunk@1420 4c0a9323-5329-0410-9bdc-e9ce6186880e
* Remove pointers from serialized file formatmdempsky@chromium.org2014-12-111-5/+9
| | | | | | | | | BUG=breakpad:621 R=thestig@chromium.org Review URL: https://breakpad.appspot.com/1764002 git-svn-id: http://google-breakpad.googlecode.com/svn/trunk@1410 4c0a9323-5329-0410-9bdc-e9ce6186880e
* Refactor .so name detection logic in minidump/linux_dumper.primiano@chromium.org2014-10-171-43/+14
| | | | | | | | | | | | | | | | This is a refactoring of the logic which determines the module name and path for a given MappingInfo in minidump_writer.cc. Such logic, which will be soon shared also with the upcoming microdump_writer.cc, is simply being moved to linux_dumper.cc, extracting a GetMappingEffectiveNameAndPath method. No behavioral change is intended. BUG=chromium:410294 R=thestig@chromium.org Review URL: https://breakpad.appspot.com/7734002 git-svn-id: http://google-breakpad.googlecode.com/svn/trunk@1392 4c0a9323-5329-0410-9bdc-e9ce6186880e
* Microdumps: refactor out common parts of minidump_writer.ccprimiano@chromium.org2014-10-011-571/+15
| | | | | | | | | | | | | | | | | | | | This change is a pure refactoring of the common bits of minidump_writer.cc that will be shared soon with the upcoming microdump_writer.cc. In particular, this CL is extracting the following classes: - ThreadInfo: handles the state of the threads in the crashing process. - RawContextCPU: typedef for arch-specific CPU context structure. - UContextReader: Fills out a dump RawContextCPU structure from the ucontext struct provided by the kernel (arch-dependent). - SeccompUnwinder: cleans out the stack frames of the Seccomp sandbox on the supported architectures. - MappingInfo: handles information about mappings BUG=chromium:410294 R=mmandlis@chromium.org Review URL: https://breakpad.appspot.com/4684002 git-svn-id: http://google-breakpad.googlecode.com/svn/trunk@1388 4c0a9323-5329-0410-9bdc-e9ce6186880e
* IWYU in minidump_writer.cc to fix building with libc++ after r1385.thestig@chromium.org2014-09-241-0/+1
| | | | | | | | R=ivanpe@chromium.org Review URL: https://breakpad.appspot.com/6744002 git-svn-id: http://google-breakpad.googlecode.com/svn/trunk@1386 4c0a9323-5329-0410-9bdc-e9ce6186880e
* Chrome on Android now supports loading the shared library directly from the ↵rmcilroy@chromium.org2014-07-221-4/+31
| | | | | | | | | | | | | | | | | | | | | | APK file. This patch makes two changes to breakpad to enable crash reporting to work correctly when the library is inside another file (an archive): - Do not filter mappings which map an executable at a non-zero offset. - If such an executable is mapped look in the ELF information for the shared object name and use that name in the minidump. Note this change doesn't care about the archive format and isn't Android specific (though loading the shared library this way is currently only done on Android). BUG=390618 R=thestig@chromium.org Review URL: https://breakpad.appspot.com/7684002 Patch from Anton Carver <anton@chromium.org>. git-svn-id: http://google-breakpad.googlecode.com/svn/trunk@1355 4c0a9323-5329-0410-9bdc-e9ce6186880e
* [Android]: Remove __system_property_get(ro.build.fingerprint) from ↵rmcilroy@chromium.org2014-07-181-17/+0
| | | | | | | | | | | | | | | WriteOSInformation. __system_property_get has been removed from the Android NDK for 'L' so Breakpad no longer links. This CL just removes the call in WriteOSInformation because Chrome already passes the build fingerprint as a crash key called "android_build_fp" in the crash report HTTP POST message. BUG=394841,393903 R=mark@chromium.org Review URL: https://breakpad.appspot.com/1694002 git-svn-id: http://google-breakpad.googlecode.com/svn/trunk@1351 4c0a9323-5329-0410-9bdc-e9ce6186880e
* Fill in CPU info in mini-dump for Arm64.rmcilroy@chromium.org2014-04-111-13/+54
| | | | | | | | | | | | Adds Arm64 varients of CPUFillThreadInfo and CPUFillFromUContext and WriteCPUInformation for the Linux/Android client. BUG=354405,335641 R=mark@chromium.org Review URL: https://breakpad.appspot.com/1464002 git-svn-id: http://google-breakpad.googlecode.com/svn/trunk@1310 4c0a9323-5329-0410-9bdc-e9ce6186880e
* Add Arm64 version of breakpad_getcontext for Android.rmcilroy@chromium.org2014-04-031-10/+11
| | | | | | | | | | | | This CL adds breakpad_getcontext support for Arm64 to Android. The assembly is based on getcontext.S in glibc. BUG=354405,335641 R=mark@chromium.org Review URL: https://breakpad.appspot.com/1384002 git-svn-id: http://google-breakpad.googlecode.com/svn/trunk@1302 4c0a9323-5329-0410-9bdc-e9ce6186880e
* First cut at adding arm64 Linux / Android support to Breakpad.rmcilroy@chromium.org2014-04-021-1/+31
| | | | | | | | | | | | | | This is an initial attempt to add Arm64 (aarch64) support to Breakpad for Linux / Android platforms. This CL adds the Arm64 data structures, but does not yet implement the Android getcontext support or CPUFillFromThreadInfo / CPUFillFromUContext. BUG=354405,335641 R=mark@chromium.org Review URL: https://breakpad.appspot.com/1354002 git-svn-id: http://google-breakpad.googlecode.com/svn/trunk@1301 4c0a9323-5329-0410-9bdc-e9ce6186880e
* Adding mips support for Android.gordana.cmiljanovic@imgtec.com2013-09-251-0/+4
| | | | | | | | | | | | | | Mips linux support has been added previously in r1212. Some additional changes are required to make breakpad functional on Android. BUG=none TEST=build, unittests, chrome test application Review URL: https://breakpad.appspot.com/632002 git-svn-id: http://google-breakpad.googlecode.com/svn/trunk@1215 4c0a9323-5329-0410-9bdc-e9ce6186880e
* Adding support for mips.gordana.cmiljanovic@imgtec.com2013-09-111-3/+82
| | | | | | | | | | | | | Support for mips cpu is added to all breakapad targets including unittests. BUG=none TEST=unittests Review URL: https://breakpad.appspot.com/614002 git-svn-id: http://google-breakpad.googlecode.com/svn/trunk@1212 4c0a9323-5329-0410-9bdc-e9ce6186880e
* Fixing several instances of std::vector::operator[] out of range accessivan.penkov@gmail.com2013-05-211-6/+10
| | | | | | Review URL: https://breakpad.appspot.com/597002 git-svn-id: http://google-breakpad.googlecode.com/svn/trunk@1187 4c0a9323-5329-0410-9bdc-e9ce6186880e
* Improve ARM CPU info reporting.digit@chromium.org2013-04-241-62/+221
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This patch improves several things for Linux/ARM: - Better detection of the number of CPUs on the target device. The content of /proc/cpuinfo only matches the number of "online" CPUs, which varies over time with recent Android devices. - Reconstruct the CPUID and ELF hwcaps values from /proc/cpuinfo, this is useful to better identify target devices in minidumps. - Make minidump_dump display the new information in useful ways. - Write a small helper class to parse /proc/cpuinfo and also use it for x86/64. - Write a small helper class to parse sysfds cpu lists. - Add a my_memchr() implementation. - Add unit tests. Tested on a Nexus S (1 CPU), Galaxy Nexus (2 CPUs) and a Nexus 4 (4 CPUs). Review URL: https://breakpad.appspot.com/540003 git-svn-id: http://google-breakpad.googlecode.com/svn/trunk@1160 4c0a9323-5329-0410-9bdc-e9ce6186880e
* Linux MinidumpWriter should properly set number_of_processors on ARMted.mielczarek@gmail.com2013-03-121-0/+4
| | | | | | | | | R=digit at http://breakpad.appspot.com/425002 This doesn't fix this problem in all possible cases, but it makes it slightly better in some cases, so I think that's a net positive. git-svn-id: http://google-breakpad.googlecode.com/svn/trunk@1131 4c0a9323-5329-0410-9bdc-e9ce6186880e
* Use stdint types everywhereted.mielczarek@gmail.com2013-03-061-9/+9
| | | | | | R=mark at https://breakpad.appspot.com/535002/ git-svn-id: http://google-breakpad.googlecode.com/svn/trunk@1121 4c0a9323-5329-0410-9bdc-e9ce6186880e
* Remove a call to new[] from WriteDSODebugStreamted.mielczarek@gmail.com2013-01-311-4/+3
| | | | | | R=mark at https://breakpad.appspot.com/523002/ git-svn-id: http://google-breakpad.googlecode.com/svn/trunk@1107 4c0a9323-5329-0410-9bdc-e9ce6186880e
* Cleaning up google-breakpad source code of signed-unsigned comparison warningsivan.penkov@gmail.com2012-11-211-1/+3
| | | | | | | | http://breakpad.appspot.com/488002/ git-svn-id: http://google-breakpad.googlecode.com/svn/trunk@1083 4c0a9323-5329-0410-9bdc-e9ce6186880e
* Add optional file size limit for minidumpsmkrebs@chromium.org2012-11-151-15/+86
| | | | | | | | | | | | | | | | | | | | | | When there are upwards of 200 threads in a crashing process, each having an 8KB stack, this can result in a huge, 1.8MB minidump file. So I added a parameter that, if set, can compel the minidump writer to dump less stack. More specifically, if the writer expects to go over the limit (due to the number of threads), then it will dump less of a thread's stack after the first 20 threads. There are two ways to specify the limit, depending on how you write minidumps: 1) If you call WriteMinidump() directly, there's now a version of the function that takes the minidump size limit as an argument. 2) If you use the ExceptionHandler class, the MinidumpDescriptor object you pass to it now has a set_size_limit() method you would call before passing it to the constructor. BUG=chromium-os:31447, chromium:154546 TEST=Wrote a size-limit unittest; Ran unittests Review URL: https://breakpad.appspot.com/487002 git-svn-id: http://google-breakpad.googlecode.com/svn/trunk@1082 4c0a9323-5329-0410-9bdc-e9ce6186880e
* Fix assertion failure in WriteMappings() for zero modulesmkrebs@chromium.org2012-11-141-2/+9
| | | | | | | | | | | If there were no mappings where ShouldIncludeMapping() returned true, AllocateObjectAndArray() would die with an assertion failure. BUG=chrome-os-partner:14914 TEST=Ran unittests Review URL: https://breakpad.appspot.com/492002 git-svn-id: http://google-breakpad.googlecode.com/svn/trunk@1081 4c0a9323-5329-0410-9bdc-e9ce6186880e
* Fix typo from r1079.thestig@chromium.org2012-11-131-1/+1
| | | | | | | TBR=digit Review URL: https://breakpad.appspot.com/496002 git-svn-id: http://google-breakpad.googlecode.com/svn/trunk@1080 4c0a9323-5329-0410-9bdc-e9ce6186880e
* Linux: Avoid truncating the vendor id.thestig@chromium.org2012-11-091-5/+3
| | | | | | Review URL: https://breakpad.appspot.com/495002 git-svn-id: http://google-breakpad.googlecode.com/svn/trunk@1079 4c0a9323-5329-0410-9bdc-e9ce6186880e
* Fix the Android unit tests.digit@chromium.org2012-10-091-4/+0
| | | | | | | | | | | | | | | | | | | - One of the unit test binaries refused to link due to missing linker flags. - The WriteDSODebug() function now works on Android, so do not special-case it anymore. - Ensure android/run-checks.sh will complain properly if the client unit test suite fails on Android. It used to consider that such failures were acceptable. Note that it still considers failures when running the tools and processor test suite on the device normal (fixing this is a lot harder, and these parts of Breakpad typically never run on a device, but on the host). Review URL: https://breakpad.appspot.com/482002 git-svn-id: http://google-breakpad.googlecode.com/svn/trunk@1066 4c0a9323-5329-0410-9bdc-e9ce6186880e
* Don't bail if a thread's stack pointer is invalidmkrebs@chromium.org2012-10-081-27/+45
| | | | | | | | | | | | | | 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
* Fix a parsing error in the Linux dump writer.thestig@chromium.org2012-09-261-7/+11
| | | | | | Review URL: https://breakpad.appspot.com/464002 git-svn-id: http://google-breakpad.googlecode.com/svn/trunk@1050 4c0a9323-5329-0410-9bdc-e9ce6186880e
* Minidumps never contain MD_LINUX_DSO_DEBUG info when breakpad is in a shared ↵ted.mielczarek@gmail.com2012-09-191-44/+56
| | | | | | | | | library A=Mike Hommey <mh@glandium.org> R=ted at http://breakpad.appspot.com/422002/ git-svn-id: http://google-breakpad.googlecode.com/svn/trunk@1044 4c0a9323-5329-0410-9bdc-e9ce6186880e
* Allow generating minidumps from live process on Linux via ExceptionHandlerted.mielczarek@gmail.com2012-09-181-1/+32
| | | | | | | Original patch by Chris Jones <jones.chris.g@gmail.com> at https://bugzilla.mozilla.org/show_bug.cgi?id=544936 and https://bugzilla.mozilla.org/show_bug.cgi?id=555309 R=mark at https://breakpad.appspot.com/449003/ git-svn-id: http://google-breakpad.googlecode.com/svn/trunk@1043 4c0a9323-5329-0410-9bdc-e9ce6186880e
* Allow adding extra memory regions to minidump on linux/windowsted.mielczarek@gmail.com2012-09-181-10/+48
| | | | | | | A=Bill McCloskey <wmccloskey@mozilla.com>, ted, original patch from https://bugzilla.mozilla.org/show_bug.cgi?id=662646 R=mark at https://breakpad.appspot.com/450002/ git-svn-id: http://google-breakpad.googlecode.com/svn/trunk@1041 4c0a9323-5329-0410-9bdc-e9ce6186880e
* Fix Linux/ARM GetInstructionPointer() in minidump_writer.ccdigit@chromium.org2012-08-301-1/+1
| | | | | | | | On ARM, the 'ip' register (a.k.a. r12) is not the same than 'pc' (a.k.a. r15) which holds the real instruction pointer. Review URL: https://breakpad.appspot.com/443002 git-svn-id: http://google-breakpad.googlecode.com/svn/trunk@1021 4c0a9323-5329-0410-9bdc-e9ce6186880e
* Improve Android supportdigit@chromium.org2012-08-211-8/+0
| | | | | | | | | | | | | | | | | | This patch remove many Android-specific #ifdefs from the Breakpad source code. This is achieved by providing "fixed-up" platform headers (e.g. <signal.h> or <sys/user,h>), in the new directory src/common/android/include/, which masks differences between the NDK and GLibc headers. The old "android_link.h" and "android_ucontext.h" are moved and renamed. This also requires putting this directory as the first include path during Android-hosted builds, hence the modification of Makefile.am and configure.ac Review URL: https://breakpad.appspot.com/434002 git-svn-id: http://google-breakpad.googlecode.com/svn/trunk@1017 4c0a9323-5329-0410-9bdc-e9ce6186880e