Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(700)

Issue 913273002: win: Implementation of CrashReportDatabase for Windows (for C++ Windows readability review) (Closed)

Created:
5 years, 10 months ago by scottmg
Modified:
5 years, 10 months ago
CC:
Mark Mentovai, Robert Sesek
Base URL:
https://chromium.googlesource.com/crashpad/crashpad@master
Target Ref:
refs/heads/master
Project:
crashpad
Visibility:
Public.

Description

win: Implementation of CrashReportDatabase for Windows (for C++ Windows readability review) Original CL (review, misc support code changes) at https://codereview.chromium.org/867363003/. Crashpad is a component of Chrome used for capturing crashes in the field and uploading them to crash/ for analysis: https://code.google.com/p/crashpad/. BUG=crashpad:1 , b/19354950 R=mark@chromium.org, pkasting@chromium.org Committed: https://chromium.googlesource.com/crashpad/crashpad/+/bd77b3034fb9d759968d30abc111bc491362eb6c

Patch Set 1 #

Total comments: 183

Patch Set 2 : address feedback #

Patch Set 3 : . #

Total comments: 8

Patch Set 4 : more changes #

Patch Set 5 : more fixes #

Total comments: 6

Patch Set 6 : feedback, add test for report being removed #

Total comments: 8

Patch Set 7 : check unlink return, add comment to MFRR ctor #

Total comments: 4

Patch Set 8 : fix test when completing report moves it #

Patch Set 9 : better unlink checks #

Unified diffs Side-by-side diffs Delta from patch set Stats (+373 lines, -327 lines) Patch
M client/crash_report_database_test.cc View 1 2 3 4 5 6 7 8 13 chunks +47 lines, -33 lines 0 comments Download
M client/crash_report_database_win.cc View 1 2 3 4 5 6 20 chunks +303 lines, -265 lines 0 comments Download
M util/misc/uuid.h View 1 2 chunks +3 lines, -2 lines 0 comments Download
M util/misc/uuid.cc View 1 1 chunk +1 line, -1 line 0 comments Download
M util/test/scoped_temp_dir.h View 1 1 chunk +1 line, -1 line 0 comments Download
M util/test/scoped_temp_dir_win.cc View 1 2 3 4 5 2 chunks +18 lines, -25 lines 0 comments Download

Messages

Total messages: 38 (11 generated)
scottmg
5 years, 10 months ago (2015-02-11 23:16:52 UTC) #3
Peter Kasting
Thanks for participating in the readability process! The change seems largely free of Google Style ...
5 years, 10 months ago (2015-02-13 00:32:41 UTC) #4
scottmg
Thanks for your thorough review! Unfortunately, because things moved around a bunch, the difference between ...
5 years, 10 months ago (2015-02-13 06:34:06 UTC) #7
Mark Mentovai
https://codereview.chromium.org/913273002/diff/20001/client/crash_report_database_test.cc File client/crash_report_database_test.cc (right): https://codereview.chromium.org/913273002/diff/20001/client/crash_report_database_test.cc#newcode46 client/crash_report_database_test.cc:46: ASSERT_NE(handle, nullptr); Peter Kasting wrote: > Nit: (expected, actual) ...
5 years, 10 months ago (2015-02-13 14:08:37 UTC) #9
Mark Mentovai
https://codereview.chromium.org/913273002/diff/20001/client/crash_report_database_win.cc File client/crash_report_database_win.cc (right): https://codereview.chromium.org/913273002/diff/20001/client/crash_report_database_win.cc#newcode277 client/crash_report_database_win.cc:277: DCHECK_EQ(result, 0); Peter Kasting wrote: > Nit: While not ...
5 years, 10 months ago (2015-02-13 14:12:46 UTC) #10
scottmg
https://codereview.chromium.org/913273002/diff/20001/client/crash_report_database_test.cc File client/crash_report_database_test.cc (right): https://codereview.chromium.org/913273002/diff/20001/client/crash_report_database_test.cc#newcode46 client/crash_report_database_test.cc:46: ASSERT_NE(handle, nullptr); On 2015/02/13 14:08:37, Mark Mentovai wrote: > ...
5 years, 10 months ago (2015-02-13 17:26:41 UTC) #11
Peter Kasting
(Have not re-reviewed, just replying) https://codereview.chromium.org/913273002/diff/20001/client/crash_report_database_test.cc File client/crash_report_database_test.cc (right): https://codereview.chromium.org/913273002/diff/20001/client/crash_report_database_test.cc#newcode131 client/crash_report_database_test.cc:131: std::vector<const CrashReportDatabase::Report> reports; On ...
5 years, 10 months ago (2015-02-13 22:30:33 UTC) #12
Mark Mentovai
https://codereview.chromium.org/913273002/diff/20001/util/test/scoped_temp_dir_posix.cc File util/test/scoped_temp_dir_posix.cc (right): https://codereview.chromium.org/913273002/diff/20001/util/test/scoped_temp_dir_posix.cc#newcode48 util/test/scoped_temp_dir_posix.cc:48: while ((entry = readdir(dir))) { scottmg wrote: > I ...
5 years, 10 months ago (2015-02-13 22:36:15 UTC) #13
Peter Kasting
https://codereview.chromium.org/913273002/diff/20001/util/test/scoped_temp_dir_posix.cc File util/test/scoped_temp_dir_posix.cc (right): https://codereview.chromium.org/913273002/diff/20001/util/test/scoped_temp_dir_posix.cc#newcode48 util/test/scoped_temp_dir_posix.cc:48: while ((entry = readdir(dir))) { On 2015/02/13 22:36:15, Mark ...
5 years, 10 months ago (2015-02-13 22:38:26 UTC) #14
Mark Mentovai
https://codereview.chromium.org/913273002/diff/20001/util/test/scoped_temp_dir_posix.cc File util/test/scoped_temp_dir_posix.cc (right): https://codereview.chromium.org/913273002/diff/20001/util/test/scoped_temp_dir_posix.cc#newcode48 util/test/scoped_temp_dir_posix.cc:48: while ((entry = readdir(dir))) { Peter Kasting wrote: > ...
5 years, 10 months ago (2015-02-13 22:42:27 UTC) #15
scottmg
https://codereview.chromium.org/913273002/diff/20001/client/crash_report_database_test.cc File client/crash_report_database_test.cc (right): https://codereview.chromium.org/913273002/diff/20001/client/crash_report_database_test.cc#newcode131 client/crash_report_database_test.cc:131: std::vector<const CrashReportDatabase::Report> reports; On 2015/02/13 22:30:32, Peter Kasting wrote: ...
5 years, 10 months ago (2015-02-13 23:37:17 UTC) #16
Peter Kasting
https://codereview.chromium.org/913273002/diff/20001/client/crash_report_database_win.cc File client/crash_report_database_win.cc (right): https://codereview.chromium.org/913273002/diff/20001/client/crash_report_database_win.cc#newcode380 client/crash_report_database_win.cc:380: << report_dir_.value().c_str(); On 2015/02/13 23:37:16, scottmg wrote: > On ...
5 years, 10 months ago (2015-02-13 23:45:10 UTC) #17
Mark Mentovai
https://codereview.chromium.org/913273002/diff/20001/client/crash_report_database_win.cc File client/crash_report_database_win.cc (right): https://codereview.chromium.org/913273002/diff/20001/client/crash_report_database_win.cc#newcode407 client/crash_report_database_win.cc:407: DCHECK(new_report_disk.state == ReportState::kPending); On 2015/02/13 23:45:10, Peter Kasting wrote: ...
5 years, 10 months ago (2015-02-13 23:58:51 UTC) #18
scottmg
https://codereview.chromium.org/913273002/diff/20001/client/crash_report_database_win.cc File client/crash_report_database_win.cc (right): https://codereview.chromium.org/913273002/diff/20001/client/crash_report_database_win.cc#newcode407 client/crash_report_database_win.cc:407: DCHECK(new_report_disk.state == ReportState::kPending); On 2015/02/13 23:45:10, Peter Kasting wrote: ...
5 years, 10 months ago (2015-02-14 00:00:47 UTC) #19
Peter Kasting
LGTM. Once this is landed, I will mark the readability request bug as fixed, which ...
5 years, 10 months ago (2015-02-14 00:24:24 UTC) #20
scottmg
Thanks. Mark, please let me know if you have any concerns before landing. https://codereview.chromium.org/913273002/diff/100001/client/crash_report_database_test.cc File ...
5 years, 10 months ago (2015-02-14 00:42:45 UTC) #22
Peter Kasting
Still LGTM https://codereview.chromium.org/913273002/diff/140001/client/crash_report_database_win.cc File client/crash_report_database_win.cc (right): https://codereview.chromium.org/913273002/diff/140001/client/crash_report_database_win.cc#newcode97 client/crash_report_database_win.cc:97: int64_t last_upload_attempt_time; // Holds a time_t. Up ...
5 years, 10 months ago (2015-02-14 00:50:22 UTC) #23
scottmg
https://codereview.chromium.org/913273002/diff/140001/client/crash_report_database_win.cc File client/crash_report_database_win.cc (right): https://codereview.chromium.org/913273002/diff/140001/client/crash_report_database_win.cc#newcode97 client/crash_report_database_win.cc:97: int64_t last_upload_attempt_time; // Holds a time_t. On 2015/02/14 00:50:22, ...
5 years, 10 months ago (2015-02-14 01:12:20 UTC) #25
Mark Mentovai
https://codereview.chromium.org/913273002/diff/160001/client/crash_report_database_win.cc File client/crash_report_database_win.cc (right): https://codereview.chromium.org/913273002/diff/160001/client/crash_report_database_win.cc#newcode92 client/crash_report_database_win.cc:92: UUID uuid; // UUID is a 16 byte, standard ...
5 years, 10 months ago (2015-02-17 17:48:48 UTC) #26
scottmg
(I stupidly fat-fingered and deleted the patchset with your most recent comments, so (re-)replying inline. ...
5 years, 10 months ago (2015-02-17 18:58:55 UTC) #29
Mark Mentovai
LGTM https://codereview.chromium.org/913273002/diff/200001/client/crash_report_database_test.cc File client/crash_report_database_test.cc (right): https://codereview.chromium.org/913273002/diff/200001/client/crash_report_database_test.cc#newcode461 client/crash_report_database_test.cc:461: _wunlink(report_path.value().c_str()); Check the return value, both branches. https://codereview.chromium.org/913273002/diff/200001/client/crash_report_database_win.cc ...
5 years, 10 months ago (2015-02-17 19:40:40 UTC) #30
scottmg
https://codereview.chromium.org/913273002/diff/200001/client/crash_report_database_test.cc File client/crash_report_database_test.cc (right): https://codereview.chromium.org/913273002/diff/200001/client/crash_report_database_test.cc#newcode461 client/crash_report_database_test.cc:461: _wunlink(report_path.value().c_str()); On 2015/02/17 19:40:40, Mark Mentovai wrote: > Check ...
5 years, 10 months ago (2015-02-17 19:52:20 UTC) #32
Mark Mentovai
Still LGTM https://codereview.chromium.org/913273002/diff/220001/client/crash_report_database_test.cc File client/crash_report_database_test.cc (right): https://codereview.chromium.org/913273002/diff/220001/client/crash_report_database_test.cc#newcode461 client/crash_report_database_test.cc:461: EXPECT_EQ(_wunlink(report_path.value().c_str()), 0); (expected, actual) for gtest. Ugh. ...
5 years, 10 months ago (2015-02-17 19:56:23 UTC) #33
scottmg
https://codereview.chromium.org/913273002/diff/220001/client/crash_report_database_test.cc File client/crash_report_database_test.cc (right): https://codereview.chromium.org/913273002/diff/220001/client/crash_report_database_test.cc#newcode461 client/crash_report_database_test.cc:461: EXPECT_EQ(_wunlink(report_path.value().c_str()), 0); On 2015/02/17 19:56:23, Mark Mentovai wrote: > ...
5 years, 10 months ago (2015-02-17 20:00:39 UTC) #35
Mark Mentovai
LGTM
5 years, 10 months ago (2015-02-17 20:03:10 UTC) #36
scottmg
Committed patchset #9 (id:260001) manually as bd77b3034fb9d759968d30abc111bc491362eb6c (presubmit successful).
5 years, 10 months ago (2015-02-17 20:05:32 UTC) #37
Peter Kasting
5 years, 10 months ago (2015-02-17 20:07:26 UTC) #38
Message was sent while issue was closed.
On 2015/02/17 20:00:39, scottmg wrote:
>
https://codereview.chromium.org/913273002/diff/220001/client/crash_report_dat...
> File client/crash_report_database_test.cc (right):
> 
>
https://codereview.chromium.org/913273002/diff/220001/client/crash_report_dat...
> client/crash_report_database_test.cc:461:
> EXPECT_EQ(_wunlink(report_path.value().c_str()), 0);
> On 2015/02/17 19:56:23, Mark Mentovai wrote:
> > (expected, actual) for gtest. Ugh.
> 
> Sigh, keep forgetting. Done.

(That's why most Chromium code simply does (expected, actual) on all _EQ or _NE
macros, inside or outside of gtest -- it's much easier to be in the habit of
doing it everywhere than to try and remember that a few cases are exceptional.)

Powered by Google App Engine
This is Rietveld 408576698