| Index: chrome/browser/chrome_content_browser_client.cc
|
| diff --git a/chrome/browser/chrome_content_browser_client.cc b/chrome/browser/chrome_content_browser_client.cc
|
| index 8c6aeaf4001dc7d3b77f70744f882cfffbcf6fa7..03c70916ffea6f54013fc39ca5f8daa6dba11f7b 100644
|
| --- a/chrome/browser/chrome_content_browser_client.cc
|
| +++ b/chrome/browser/chrome_content_browser_client.cc
|
| @@ -340,10 +340,8 @@ bool ChromeContentBrowserClient::AllowAppCache(
|
| ProfileIOData* io_data =
|
| reinterpret_cast<ProfileIOData*>(context.GetUserData(NULL));
|
| // FIXME(jochen): get the correct top-level origin.
|
| - ContentSetting setting = io_data->GetHostContentSettingsMap()->
|
| - GetCookieContentSetting(manifest_url, manifest_url, true);
|
| - DCHECK(setting != CONTENT_SETTING_DEFAULT);
|
| - return setting != CONTENT_SETTING_BLOCK;
|
| + return io_data->GetCookieContentSettings()->Allow(
|
| + manifest_url, manifest_url, true);
|
| }
|
|
|
| bool ChromeContentBrowserClient::AllowGetCookie(
|
| @@ -356,10 +354,8 @@ bool ChromeContentBrowserClient::AllowGetCookie(
|
| DCHECK(BrowserThread::CurrentlyOn(BrowserThread::IO));
|
| ProfileIOData* io_data =
|
| reinterpret_cast<ProfileIOData*>(context.GetUserData(NULL));
|
| - ContentSetting setting = io_data->GetHostContentSettingsMap()->
|
| - GetCookieContentSetting(url, first_party, false);
|
| - bool allow = setting == CONTENT_SETTING_ALLOW ||
|
| - setting == CONTENT_SETTING_SESSION_ONLY;
|
| + bool allow = io_data->GetCookieContentSettings()->Allow(
|
| + url, first_party, false);
|
|
|
| BrowserThread::PostTask(
|
| BrowserThread::UI, FROM_HERE,
|
| @@ -380,14 +376,12 @@ bool ChromeContentBrowserClient::AllowSetCookie(
|
| DCHECK(BrowserThread::CurrentlyOn(BrowserThread::IO));
|
| ProfileIOData* io_data =
|
| reinterpret_cast<ProfileIOData*>(context.GetUserData(NULL));
|
| - ContentSetting setting = io_data->GetHostContentSettingsMap()->
|
| - GetCookieContentSetting(url, first_party, true);
|
|
|
| - if (setting == CONTENT_SETTING_SESSION_ONLY)
|
| - options->set_force_session();
|
| + bool allow = io_data->GetCookieContentSettings()->Allow(
|
| + url, first_party, true);
|
|
|
| - bool allow = setting == CONTENT_SETTING_ALLOW ||
|
| - setting == CONTENT_SETTING_SESSION_ONLY;
|
| + if (io_data->GetCookieContentSettings()->EnforceSessionOnly(url))
|
| + options->set_force_session();
|
|
|
| BrowserThread::PostTask(
|
| BrowserThread::UI, FROM_HERE,
|
|
|