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

Unified Diff: rlz/lib/financial_ping.cc

Issue 14818006: Merge 197214 "Detect when chrome is shutting down and don't Send..." (Closed) Base URL: svn://svn.chromium.org/chrome/branches/1453/src/
Patch Set: Created 7 years, 8 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « chrome/browser/rlz/rlz.cc ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: rlz/lib/financial_ping.cc
===================================================================
--- rlz/lib/financial_ping.cc (revision 198117)
+++ rlz/lib/financial_ping.cc (working copy)
@@ -265,6 +265,10 @@
return true;
#else
+ // Browser shutdown will cause the context to be reset to NULL.
+ if (!g_context)
+ return false;
+
// Run a blocking event loop to match the win inet implementation.
scoped_ptr<MessageLoop> message_loop;
// Ensure that we have a MessageLoop.
@@ -288,7 +292,6 @@
// Ensure rlz_lib::SetURLRequestContext() has been called before sending
// pings.
- CHECK(g_context);
fetcher->SetRequestContext(g_context);
const base::TimeDelta kTimeout = base::TimeDelta::FromMinutes(5);
« no previous file with comments | « chrome/browser/rlz/rlz.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698