summaryrefslogtreecommitdiffstats
path: root/breakpad/linux/generate-test-dump.cc
diff options
context:
space:
mode:
authorjcivelli@chromium.org <jcivelli@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2012-08-15 00:08:04 +0000
committerjcivelli@chromium.org <jcivelli@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2012-08-15 00:08:04 +0000
commit5d5c289204cc7d5d77bc775177867bbb0cc947ea (patch)
tree7df6395da53814b12562da392283044ffa94b44a /breakpad/linux/generate-test-dump.cc
parentb8d10fddbc208a179ed76a6b43ded87079bdbe14 (diff)
downloadchromium_src-5d5c289204cc7d5d77bc775177867bbb0cc947ea.zip
chromium_src-5d5c289204cc7d5d77bc775177867bbb0cc947ea.tar.gz
chromium_src-5d5c289204cc7d5d77bc775177867bbb0cc947ea.tar.bz2
Rolling the DEPS of Breakpad.
Rolling the DEPS of Breakpad in order to get the file descriptor support for generating minidumps, it is needed on Android. BUG=None TEST=Breakpad unit-tests should compile and run. Review URL: https://chromiumcodereview.appspot.com/10825329 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@151612 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'breakpad/linux/generate-test-dump.cc')
-rw-r--r--breakpad/linux/generate-test-dump.cc13
1 files changed, 6 insertions, 7 deletions
diff --git a/breakpad/linux/generate-test-dump.cc b/breakpad/linux/generate-test-dump.cc
index f933ab4..b0dca00 100644
--- a/breakpad/linux/generate-test-dump.cc
+++ b/breakpad/linux/generate-test-dump.cc
@@ -37,7 +37,7 @@
#include "breakpad/src/common/linux/linux_libc_support.h"
#include "third_party/lss/linux_syscall_support.h"
-static bool DumpCallback(const char* dump_path, const char* minidump_id,
+static bool DumpCallback(const google_breakpad::MinidumpDescriptor& descriptor,
void* context, bool success) {
if (!success) {
static const char msg[] = "Failed to write minidump\n";
@@ -47,10 +47,8 @@ static bool DumpCallback(const char* dump_path, const char* minidump_id,
static const char msg[] = "Wrote minidump: ";
sys_write(2, msg, sizeof(msg) - 1);
- sys_write(2, dump_path, my_strlen(dump_path));
- sys_write(2, "/", 1);
- sys_write(2, minidump_id, my_strlen(minidump_id));
- sys_write(2, ".dmp\n", 5);
+ sys_write(2, descriptor.path(), strlen(descriptor.path()));
+ sys_write(2, "\n", 1);
return true;
}
@@ -61,8 +59,9 @@ static void DoSomethingWhichCrashes() {
}
int main() {
- google_breakpad::ExceptionHandler breakpad(".", NULL, DumpCallback, NULL,
- true);
+ google_breakpad::MinidumpDescriptor minidump(".");
+ google_breakpad::ExceptionHandler breakpad(minidump, NULL, DumpCallback, NULL,
+ true, -1);
DoSomethingWhichCrashes();
return 0;
}