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

Issue 1856823002: Add null-check in OmahaClient for handling intent. (Closed)

Created:
4 years, 8 months ago by Peter Wen
Modified:
4 years, 8 months ago
Reviewers:
gone
CC:
chromium-reviews
Base URL:
https://chromium.googlesource.com/chromium/src.git@master
Target Ref:
refs/pending/heads/master
Project:
chromium
Visibility:
Public.

Description

Add null-check in OmahaClient for handling intent. Since getRequestGenerator() is used without null guards in all subsequent calls, it should be verified before making those calls. This check will be extremely quick if ChromeApplication returns null, and it will only incur a one-time cost otherwise, and this is not on the UI thread, so it should have minimal performance impact. BUG=584114 Committed: https://crrev.com/85705c2257f562b092c8d04996683439e43ce76f Cr-Commit-Position: refs/heads/master@{#384955}

Patch Set 1 #

Total comments: 2

Patch Set 2 : Move check earlier. #

Unified diffs Side-by-side diffs Delta from patch set Stats (+4 lines, -0 lines) Patch
M chrome/android/java/src/org/chromium/chrome/browser/omaha/OmahaClient.java View 1 1 chunk +4 lines, -0 lines 0 comments Download

Messages

Total messages: 10 (4 generated)
Peter Wen
🚀
4 years, 8 months ago (2016-04-04 16:31:52 UTC) #2
gone
lgtm https://codereview.chromium.org/1856823002/diff/1/chrome/android/java/src/org/chromium/chrome/browser/omaha/OmahaClient.java File chrome/android/java/src/org/chromium/chrome/browser/omaha/OmahaClient.java (right): https://codereview.chromium.org/1856823002/diff/1/chrome/android/java/src/org/chromium/chrome/browser/omaha/OmahaClient.java#newcode205 chrome/android/java/src/org/chromium/chrome/browser/omaha/OmahaClient.java:205: if (getRequestGenerator() == null) { I'd actually move ...
4 years, 8 months ago (2016-04-04 17:06:45 UTC) #3
Peter Wen
Thanks for the quick review! :) https://codereview.chromium.org/1856823002/diff/1/chrome/android/java/src/org/chromium/chrome/browser/omaha/OmahaClient.java File chrome/android/java/src/org/chromium/chrome/browser/omaha/OmahaClient.java (right): https://codereview.chromium.org/1856823002/diff/1/chrome/android/java/src/org/chromium/chrome/browser/omaha/OmahaClient.java#newcode205 chrome/android/java/src/org/chromium/chrome/browser/omaha/OmahaClient.java:205: if (getRequestGenerator() == ...
4 years, 8 months ago (2016-04-04 17:25:42 UTC) #4
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/1856823002/20001 View timeline at https://chromium-cq-status.appspot.com/patch-timeline/1856823002/20001
4 years, 8 months ago (2016-04-04 17:26:08 UTC) #7
commit-bot: I haz the power
Committed patchset #2 (id:20001)
4 years, 8 months ago (2016-04-04 18:09:05 UTC) #8
commit-bot: I haz the power
4 years, 8 months ago (2016-04-04 18:10:12 UTC) #10
Message was sent while issue was closed.
Patchset 2 (id:??) landed as
https://crrev.com/85705c2257f562b092c8d04996683439e43ce76f
Cr-Commit-Position: refs/heads/master@{#384955}

Powered by Google App Engine
This is Rietveld 408576698