Inherits SupportsWeakPtr<T> instead of having WeakPtrFactory<T>

This change refines r137676.

BUG=122654
TEST=browser_test


Review URL: https://chromiumcodereview.appspot.com/10332233

git-svn-id: svn://svn.chromium.org/chrome/trunk/src@139771 0039d316-1c4b-4281-b951-d872f2087c98
void ResourceDispatcherHostImpl::OnCertificateRequested(
    net::URLRequest* request,
    net::SSLCertRequestInfo* cert_request_info) {
  DCHECK(request);
  if (delegate_ && !delegate_->AcceptSSLClientCertificateRequest(
          request, cert_request_info)) {
    request->Cancel();
    return;
  }

  if (cert_request_info->client_certs.empty()) {
    request->ContinueWithCertificate(NULL);
    return;
  }

  ResourceRequestInfoImpl* info = ResourceRequestInfoImpl::ForRequest(request);
  DCHECK(!info->ssl_client_auth_handler()) <<
      "OnCertificateRequested called with ssl_client_auth_handler pending";
  info->set_ssl_client_auth_handler(
      new SSLClientAuthHandler(request, cert_request_info));
  info->ssl_client_auth_handler()->SelectCertificate();
}

void ResourceDispatcherHostImpl::OnCertificateRequested(
    net::URLRequest* request,
    net::SSLCertRequestInfo* cert_request_info) {
  DCHECK(request);
  if (delegate_ && !delegate_->AcceptSSLClientCertificateRequest(
          request, cert_request_info)) {
    request->Cancel();
    return;
  }

  if (cert_request_info->client_certs.empty()) {
    request->ContinueWithCertificate(NULL);
    return;
  }

  ResourceRequestInfoImpl* info = ResourceRequestInfoImpl::ForRequest(request);
  DCHECK(!info->ssl_client_auth_handler()) <<
      "OnCertificateRequested called with ssl_client_auth_handler pending";
  info->set_ssl_client_auth_handler(
      new SSLClientAuthHandler(request, cert_request_info));
  info->ssl_client_auth_handler()->SelectCertificate();
}
