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

Side by Side Diff: chrome/browser/search/search.cc

Issue 2561963002: base: Remove the string logging from CHECK(). (Closed)
Patch Set: checkstring: rebase Created 4 years 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 unified diff | Download patch
OLDNEW
1 // Copyright 2012 The Chromium Authors. All rights reserved. 1 // Copyright 2012 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "chrome/browser/search/search.h" 5 #include "chrome/browser/search/search.h"
6 6
7 #include <stddef.h> 7 #include <stddef.h>
8 8
9 #include "base/command_line.h" 9 #include "base/command_line.h"
10 #include "base/feature_list.h" 10 #include "base/feature_list.h"
(...skipping 378 matching lines...) Expand 10 before | Expand all | Expand 10 after
389 389
390 GURL GetNewTabPageURL(Profile* profile) { 390 GURL GetNewTabPageURL(Profile* profile) {
391 return NewTabURLDetails::ForProfile(profile).url; 391 return NewTabURLDetails::ForProfile(profile).url;
392 } 392 }
393 393
394 GURL GetSearchResultPrefetchBaseURL(Profile* profile) { 394 GURL GetSearchResultPrefetchBaseURL(Profile* profile) {
395 return ShouldPrefetchSearchResults() ? GetInstantURL(profile, true) : GURL(); 395 return ShouldPrefetchSearchResults() ? GetInstantURL(profile, true) : GURL();
396 } 396 }
397 397
398 GURL GetEffectiveURLForInstant(const GURL& url, Profile* profile) { 398 GURL GetEffectiveURLForInstant(const GURL& url, Profile* profile) {
399 CHECK(ShouldAssignURLToInstantRenderer(url, profile)) 399 // Error granting Instant access.
400 << "Error granting Instant access."; 400 CHECK(ShouldAssignURLToInstantRenderer(url, profile));
401 401
402 if (url.SchemeIs(chrome::kChromeSearchScheme)) 402 if (url.SchemeIs(chrome::kChromeSearchScheme))
403 return url; 403 return url;
404 404
405 // Replace the scheme with "chrome-search:", and clear the port, since 405 // Replace the scheme with "chrome-search:", and clear the port, since
406 // chrome-search is a scheme without port. 406 // chrome-search is a scheme without port.
407 url::Replacements<char> replacements; 407 url::Replacements<char> replacements;
408 std::string search_scheme(chrome::kChromeSearchScheme); 408 std::string search_scheme(chrome::kChromeSearchScheme);
409 replacements.SetScheme(search_scheme.data(), 409 replacements.SetScheme(search_scheme.data(),
410 url::Component(0, search_scheme.length())); 410 url::Component(0, search_scheme.length()));
(...skipping 44 matching lines...) Expand 10 before | Expand all | Expand 10 after
455 455
456 if (IsInstantNTPURL(*url, profile)) { 456 if (IsInstantNTPURL(*url, profile)) {
457 *url = GURL(chrome::kChromeUINewTabURL); 457 *url = GURL(chrome::kChromeUINewTabURL);
458 return true; 458 return true;
459 } 459 }
460 460
461 return false; 461 return false;
462 } 462 }
463 463
464 } // namespace search 464 } // namespace search
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698