From 5f6e1f0fe74bc01878d80531a91c39df9dfaa62a Mon Sep 17 00:00:00 2001 From: "ivan.penkov@gmail.com" Date: Mon, 2 Jul 2012 22:55:57 +0000 Subject: Fixing various compiler warnings and applying minor tweaks to allow running of the mojority of breakpad unittests in Google. http://breakpad.appspot.com/399002/ git-svn-id: http://google-breakpad.googlecode.com/svn/trunk@978 4c0a9323-5329-0410-9bdc-e9ce6186880e --- src/tools/linux/md2core/minidump-2-core.cc | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'src/tools') diff --git a/src/tools/linux/md2core/minidump-2-core.cc b/src/tools/linux/md2core/minidump-2-core.cc index 05357aba..5b20175b 100644 --- a/src/tools/linux/md2core/minidump-2-core.cc +++ b/src/tools/linux/md2core/minidump-2-core.cc @@ -49,10 +49,10 @@ #include "client/linux/minidump_writer/minidump_extension_linux.h" #include "common/linux/memory_mapped_file.h" #include "google_breakpad/common/minidump_format.h" +#include "processor/scoped_ptr.h" #include "third_party/lss/linux_syscall_support.h" #include "tools/linux/md2core/minidump_memory_range.h" - #if __WORDSIZE == 64 #define ELF_CLASS ELFCLASS64 #else @@ -1100,9 +1100,9 @@ main(int argc, char** argv) { } if (note_align) { - char scratch[note_align]; - memset(scratch, 0, sizeof(scratch)); - if (!writea(1, scratch, sizeof(scratch))) + google_breakpad::scoped_array scratch(new char[note_align]); + memset(scratch.get(), 0, note_align); + if (!writea(1, scratch.get(), note_align)) return 1; } -- cgit v1.2.1