2361 Commits

Author SHA1 Message Date
Mark Mentovai
859560f70d Add MinidumpFileWriter and its test.
MinidumpFileWriter writes the top-level object to a minidump file. This
consists of a MINIDUMP_HEADER and a list of MINIDUMP_DIRECTORY entries
that point to streams, which are second-level objects in minidump files.
This change also adds the base class for stream writers,
MinidumpStreamWriter.

TEST=minidump_test MinidumpFileWriter*
R=rsesek@chromium.org

Review URL: https://codereview.chromium.org/432863006
2014-08-03 18:47:34 -04:00
Mark Mentovai
3cad76870c Update mini_chromium to bd605a3773f5.
bd605a3773f5 Fix RandBytesAsString().

R=rsesek@chromium.org

Review URL: https://codereview.chromium.org/416323004
2014-08-03 17:57:41 -04:00
Mark Mentovai
5bbb7e8abb Fix the UUID structure to have distinct fields, as expected by
Breakpad’s minidump reader.

TEST=util_test UUID.UUID
R=rsesek@chromium.org

Review URL: https://codereview.chromium.org/436933002
2014-08-01 16:10:58 -04:00
Mark Mentovai
d2675ce50b Introduce MinidumpStringWriter and its test.
MinidumpStringWriter is responsible for writing variable-length UTF-16
(MINIDUMP_STRING) and UTF-8 (MinidumpUTF8String) strings to minidump
files.

This change depends on https://codereview.chromium.org/430003003/ and
https://codereview.chromium.org/435013002/.

TEST=minidump_test MinidumpStringWriter.*
R=rsesek@chromium.org

Review URL: https://codereview.chromium.org/431363002
2014-08-01 14:44:57 -04:00
Mark Mentovai
4d6b867a1f Add UUID, c16lcpy (strlcpy for char16*), and their tests to util.
These are dependencies of the upcoming MinidumpStringWriter.

R=rsesek@chromium.org

Review URL: https://codereview.chromium.org/430003003
2014-08-01 14:39:55 -04:00
Mark Mentovai
5ba343ccf1 Add minidump_extensions.h, which defines Crashpad/Breakpad extensions to
the standard minidump format defined in dbghelp.h.

R=rsesek@chromium.org

Review URL: https://codereview.chromium.org/435013002
2014-08-01 14:37:20 -04:00
Mark Mentovai
6e720f1421 Fix StringFileWriter::Seek().
The final range check needs to check that the value fits in a size_t,
because that’s what StringFileWriter uses for its offset_.

TEST=util_test StringFileWriter.SeekInvalid
R=rsesek@chromium.org

Review URL: https://codereview.chromium.org/434103003
2014-08-01 13:30:27 -04:00
Mark Mentovai
995012534e Introduce MinidumpWritable, its dependencies, and their tests.
MinidumpWritable is the base class for all minidump-writing operations.

R=rsesek@chromium.org

Review URL: https://codereview.chromium.org/432003005
2014-08-01 12:48:28 -04:00
Mark Mentovai
dfe81014f7 Add compat to Crashpad.
compat includes headers providing definitions normally provided by the
system, in cases where the system SDK does not always provide the
correct or up-to-date definitions, and cases where code on different
platforms needs to access definitions normally only available on one
platform.

To provide definitions on a single platform, where the system SDK may
not provide the definitions correctly, use subdirectories named for the
platform, such as “mac”.

To provide definitions normally available on only one platform to
others, use subdirectories that identify that they are to be used on
platforms other than the one that originated their definitions, such as
“non_win”.

In all cases, headers should be named as they are natively in their
respective SDKs, so that it’s possible to #include them according to
their usual names.

R=rsesek@chromium.org

Review URL: https://codereview.chromium.org/432843002
2014-07-31 13:45:51 -04:00
Mark Mentovai
fbcd680b50 Initial commit of Crashpad.
This commit contains the basic structure of the project:
 - LICENSE and related files.
 - DEPS to check dependencies out into third_party.
 - README.crashpad files and .gyp files to accompany third_party
   dependencies.
 - Infrastructure to run GYP as a gclient hook.
 - codereview.settings to enable Rietveld code review.
 - Assorted other administrative and dot-files.

R=rsesek@chromium.org

Review URL: https://codereview.chromium.org/426403002
2014-07-30 23:24:58 -04:00
Chase Phillips
b39398134c Initial empty repository 2014-07-30 21:15:14 +00:00