DescriptionAvoid creating BrowserThreadGlobals when we don't need to.
In tessts, it is possible for BrowserThread static methods like
IsWellKnownThread to get called when no message loops exists. We can
infer the answer for many methods from the fact the globals are
NULL without having to construct them. (constructing them can have the
undesireable side effect in these cases of hitting DCHECK for
MessageLoop::current() in the SequencedWorkerPool constructor)
BUG=117940
TEST=out/Debug/unit_tests --gtest_filter=TemplateURLPrepopulateDataTest.ProvidersFromPrefs
Committed: http://src.chromium.org/viewvc/chrome?view=rev&revision=126626
Patch Set 1 #Patch Set 2 : whitespace #Patch Set 3 : revert d'tor changes, as globals are sure to exist already here #Messages
Total messages: 7 (0 generated)
|