Rietveld Code Review Tool
Help | Bug tracker | Discussion group | Source code | Sign in
(207)

Issue 487002: Add optional file size limit for minidumps (Closed)

Can't Edit
Can't Publish+Mail
Start Review
Created:
12 years, 1 month ago by Michael Krebs
Modified:
12 years ago
CC:
google-breakpad-dev_googlegroups.com
Base URL:
http://google-breakpad.googlecode.com/svn/trunk/
Visibility:
Public.

Description

Add optional file size limit for minidumps

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
Committed: https://code.google.com/p/google-breakpad/source/detail?r=1082

Patch Set 1 #

Patch Set 2 : #

Total comments: 2
Unified diffs Side-by-side diffs Delta from patch set Stats Patch
M src/client/linux/handler/exception_handler.cc View 2 chunks +2 lines, -0 lines 0 comments Download
M src/client/linux/handler/minidump_descriptor.h View 3 chunks +11 lines, -2 lines 2 comments Download
M src/client/linux/minidump_writer/minidump_writer.cc View 12 chunks +85 lines, -15 lines 0 comments Download
M src/client/linux/minidump_writer/minidump_writer.h View 1 chunk +12 lines, -0 lines 0 comments Download
M src/client/linux/minidump_writer/minidump_writer_unittest.cc View 1 chunk +153 lines, -0 lines 0 comments Download

Messages

Total messages: 6
Michael Krebs
Could one (or both) of you please review this? There's been an increase in crashes ...
12 years, 1 month ago #1
Mark Mentovai
I’m unable to perform reviews for at least the rest of this week. On Sat, ...
12 years, 1 month ago #2
Michael Krebs
Adding benchan@ as reviewer in case he can look at this CL this week...
12 years, 1 month ago #3
Michael Krebs
Adding Ivan, as maybe he can take a look at this...
12 years ago #4
Ivan Penkov
LGTM https://breakpad.appspot.com/487002/diff/3001/src/client/linux/handler/minidump_descriptor.h File src/client/linux/handler/minidump_descriptor.h (right): https://breakpad.appspot.com/487002/diff/3001/src/client/linux/handler/minidump_descriptor.h#newcode78 src/client/linux/handler/minidump_descriptor.h:78: off_t size_limit() const { return size_limit_; } Don't ...
12 years ago #5
Michael Krebs
12 years ago #6
Thanks, Ivan!

https://breakpad.appspot.com/487002/diff/3001/src/client/linux/handler/minidu...
File src/client/linux/handler/minidump_descriptor.h (right):

https://breakpad.appspot.com/487002/diff/3001/src/client/linux/handler/minidu...
src/client/linux/handler/minidump_descriptor.h:78: off_t size_limit() const {
return size_limit_; }
Good catch.  It compiled for me, so it must have been included by other headers.
 I went ahead and explicitly added it.
Sign in to reply to this message.

Powered by Google App Engine
RSS Feeds Recent Issues | This issue
This is Rietveld 1004:630ec63f810e-tainted