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

Issue 23441026: Don't check the result of new for NULL. (Closed)

Created:
7 years, 3 months ago by Nico
Modified:
7 years, 2 months ago
CC:
chromium-reviews, cbentzel+watch_chromium.org
Visibility:
Public.

Description

Don't check the result of new for NULL. new throws on allocation error. We build with exceptions disabled, but we use an allocator that crashes the process when memory allocation fails, so this check isn't necessary. Fixes some issues reported by PVS-Studio: http://www.viva64.com/en/b/0205/ BUG=271530 NOTRY=true Committed: https://src.chromium.org/viewvc/chrome?view=rev&revision=229058

Patch Set 1 #

Total comments: 3
Unified diffs Side-by-side diffs Delta from patch set Stats (+2 lines, -9 lines) Patch
M chrome/tools/crash_service/crash_service.cc View 1 chunk +0 lines, -4 lines 0 comments Download
M net/tools/crash_cache/crash_cache.cc View 1 chunk +1 line, -1 line 3 comments Download
M ppapi/cpp/websocket.cc View 1 chunk +1 line, -4 lines 0 comments Download

Messages

Total messages: 16 (0 generated)
Nico
thestig: chrome/ akalin: net/ yzshen: ppapi/
7 years, 3 months ago (2013-08-31 03:37:02 UTC) #1
yzshen1
ppapi LGTM
7 years, 3 months ago (2013-09-01 07:43:14 UTC) #2
Lei Zhang
For the code in a tools directory, does the assumption that the allocator crashes the ...
7 years, 3 months ago (2013-09-02 20:09:34 UTC) #3
rvargas (doing something else)
https://codereview.chromium.org/23441026/diff/1/net/tools/crash_cache/crash_cache.cc File net/tools/crash_cache/crash_cache.cc (right): https://codereview.chromium.org/23441026/diff/1/net/tools/crash_cache/crash_cache.cc#newcode271 net/tools/crash_cache/crash_cache.cc:271: if (!cache->SetMaxSize(0x100000)) Can we leave this as it was? ...
7 years, 3 months ago (2013-09-03 19:01:05 UTC) #4
Nico
https://codereview.chromium.org/23441026/diff/1/net/tools/crash_cache/crash_cache.cc File net/tools/crash_cache/crash_cache.cc (right): https://codereview.chromium.org/23441026/diff/1/net/tools/crash_cache/crash_cache.cc#newcode271 net/tools/crash_cache/crash_cache.cc:271: if (!cache->SetMaxSize(0x100000)) On 2013/09/03 19:01:06, rvargas wrote: > Can ...
7 years, 3 months ago (2013-09-03 19:17:32 UTC) #5
akalin
removing myself from reviewers, as looks like rvargas is handling it
7 years, 2 months ago (2013-10-07 23:28:07 UTC) #6
rvargas (doing something else)
lgtm https://codereview.chromium.org/23441026/diff/1/net/tools/crash_cache/crash_cache.cc File net/tools/crash_cache/crash_cache.cc (right): https://codereview.chromium.org/23441026/diff/1/net/tools/crash_cache/crash_cache.cc#newcode271 net/tools/crash_cache/crash_cache.cc:271: if (!cache->SetMaxSize(0x100000)) On 2013/09/03 19:17:33, Nico wrote: > ...
7 years, 2 months ago (2013-10-16 19:01:23 UTC) #7
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/thakis@chromium.org/23441026/1
7 years, 2 months ago (2013-10-16 19:04:01 UTC) #8
Lei Zhang
lgtm
7 years, 2 months ago (2013-10-16 20:27:24 UTC) #9
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/thakis@chromium.org/23441026/1
7 years, 2 months ago (2013-10-16 20:36:25 UTC) #10
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/thakis@chromium.org/23441026/1
7 years, 2 months ago (2013-10-16 21:20:21 UTC) #11
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/thakis@chromium.org/23441026/1
7 years, 2 months ago (2013-10-17 00:09:04 UTC) #12
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/thakis@chromium.org/23441026/1
7 years, 2 months ago (2013-10-17 01:26:57 UTC) #13
commit-bot: I haz the power
Step "update" is always a major failure. Look at the try server FAQ for more ...
7 years, 2 months ago (2013-10-17 03:56:33 UTC) #14
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/thakis@chromium.org/23441026/1
7 years, 2 months ago (2013-10-17 04:12:30 UTC) #15
commit-bot: I haz the power
7 years, 2 months ago (2013-10-17 05:50:36 UTC) #16
Message was sent while issue was closed.
Change committed as 229058

Powered by Google App Engine
This is Rietveld 408576698