Code:  URLFetcher* FakeURLFetcherFactory::CreateURLFetcher(
    int id,
    const GURL& url,
    URLFetcher::RequestType request_type,
     URLFetcher::Delegate* d) {
   FakeResponseMap::const_iterator it = fake_responses_.find(url);
   if (it == fake_responses_.end()) {
    DLOG(ERROR) << "No baked response for URL: " << url.spec();
    return NULL;
   }
   return new FakeURLFetcher(url, request_type, d,
                             it->second.first, it->second.second);
}

Vulnerability Type: DoS 
CWE ID: CWE-399
Summary: Use-after-free vulnerability in Google Chrome before 13.0.782.107 allows remote attackers to cause a denial of service or possibly have unspecified other impact via vectors related to media selectors.
Commit Message: Use URLFetcher::Create instead of new in http_bridge.cc.

 This change modified http_bridge so that it uses a factory to construct
the URLFetcher. Moreover, it modified sync_backend_host_unittest.cc to
use an URLFetcher factory which will prevent access to www.example.com during
the test.

BUG=none
TEST=sync_backend_host_unittest.cc

Review URL: http://codereview.chromium.org/7053011

git-svn-id: svn://svn.chromium.org/chrome/trunk/src@87227 0039d316-1c4b-4281-b951-d872f2087c98