Index: net/url_request/url_request.cc |
diff --git a/net/url_request/url_request.cc b/net/url_request/url_request.cc |
index 8ea6325d819e072b5ad455b4c68867c90b7fa131..8fb16224a86727cc227d48b7b7f3f8f2d83c5c4e 100644 |
--- a/net/url_request/url_request.cc |
+++ b/net/url_request/url_request.cc |
@@ -610,7 +610,7 @@ void URLRequest::NotifyResponseStarted() { |
// In some cases (e.g. an event was canceled), we might have sent the |
// completion event and receive a NotifyResponseStarted() later. |
if (!has_notified_completion_ && status_.is_success()) { |
- if (context_ && context_->network_delegate()) |
+ if (context_->network_delegate()) |
context_->network_delegate()->NotifyResponseStarted(this); |
} |
@@ -694,7 +694,7 @@ int URLRequest::Redirect(const GURL& location, int http_status_code) { |
NetLog::StringCallback("location", &location.possibly_invalid_spec())); |
} |
- if (context_ && context_->network_delegate()) |
+ if (context_->network_delegate()) |
context_->network_delegate()->NotifyBeforeRedirect(this, location); |
if (redirect_limit_ <= 0) { |
@@ -788,7 +788,7 @@ void URLRequest::NotifyAuthRequired(AuthChallengeInfo* auth_info) { |
NetworkDelegate::AuthRequiredResponse rv = |
NetworkDelegate::AUTH_REQUIRED_RESPONSE_NO_ACTION; |
auth_info_ = auth_info; |
- if (context_ && context_->network_delegate()) { |
+ if (context_->network_delegate()) { |
rv = context_->network_delegate()->NotifyAuthRequired( |
this, |
*auth_info, |
@@ -855,7 +855,7 @@ void URLRequest::NotifySSLCertificateError(const SSLInfo& ssl_info, |
bool URLRequest::CanGetCookies(const CookieList& cookie_list) const { |
DCHECK(!(load_flags_ & LOAD_DO_NOT_SEND_COOKIES)); |
- if (context_ && context_->network_delegate()) { |
+ if (context_->network_delegate()) { |
return context_->network_delegate()->CanGetCookies(*this, |
cookie_list); |
} |
@@ -865,7 +865,7 @@ bool URLRequest::CanGetCookies(const CookieList& cookie_list) const { |
bool URLRequest::CanSetCookie(const std::string& cookie_line, |
CookieOptions* options) const { |
DCHECK(!(load_flags_ & LOAD_DO_NOT_SAVE_COOKIES)); |
- if (context_ && context_->network_delegate()) { |
+ if (context_->network_delegate()) { |
return context_->network_delegate()->CanSetCookie(*this, |
cookie_line, |
options); |
@@ -893,7 +893,7 @@ void URLRequest::NotifyRequestCompleted() { |
is_pending_ = false; |
has_notified_completion_ = true; |
- if (context_ && context_->network_delegate()) |
+ if (context_->network_delegate()) |
context_->network_delegate()->NotifyCompleted(this, job_ != NULL); |
} |