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

Unified Diff: chrome/browser/local_discovery/privet_url_fetcher.h

Issue 1441993004: Hide PrivetHttpClient inside of PrivetV3Session (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@context4
Patch Set: Created 5 years, 1 month 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/extensions/api/gcd_private/privet_v3_session_unittest.cc ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/local_discovery/privet_url_fetcher.h
diff --git a/chrome/browser/local_discovery/privet_url_fetcher.h b/chrome/browser/local_discovery/privet_url_fetcher.h
index f157b3dcd49b08e0995cfd58f18492e6d0cd6d9d..68846337227c456a08ad183ee5efa99a78a44701 100644
--- a/chrome/browser/local_discovery/privet_url_fetcher.h
+++ b/chrome/browser/local_discovery/privet_url_fetcher.h
@@ -103,8 +103,12 @@ class PrivetURLFetcher : public net::URLFetcherDelegate {
void SetUploadFilePath(const std::string& upload_content_type,
const base::FilePath& upload_file_path);
- const GURL& url() const { return url_fetcher_->GetOriginalURL(); }
- int response_code() const { return url_fetcher_->GetResponseCode(); }
+ const GURL& url() const {
+ return url_fetcher_ ? url_fetcher_->GetOriginalURL() : url_;
+ }
+ int response_code() const {
+ return url_fetcher_ ? url_fetcher_->GetResponseCode() : -1;
+ }
private:
void OnURLFetchCompleteParseData(const net::URLFetcher* source);
« no previous file with comments | « chrome/browser/extensions/api/gcd_private/privet_v3_session_unittest.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698