| Index: chrome/browser/automation/automation_provider.cc
|
| ===================================================================
|
| --- chrome/browser/automation/automation_provider.cc (revision 56788)
|
| +++ chrome/browser/automation/automation_provider.cc (working copy)
|
| @@ -1245,12 +1245,7 @@
|
| NavigationController* tab = tab_tracker_->GetResource(handle);
|
|
|
| // Since we are running on the UI thread don't call GetURLRequestContext().
|
| - scoped_refptr<URLRequestContextGetter> request_context =
|
| - tab->tab_contents()->request_context();
|
| - if (!request_context.get())
|
| - request_context = tab->profile()->GetRequestContext();
|
| -
|
| - *value = GetCookiesForURL(url, request_context.get());
|
| + *value = GetCookiesForURL(url, tab->profile()->GetRequestContext());
|
| *value_size = static_cast<int>(value->size());
|
| }
|
| }
|
| @@ -1264,12 +1259,7 @@
|
| if (url.is_valid() && tab_tracker_->ContainsHandle(handle)) {
|
| NavigationController* tab = tab_tracker_->GetResource(handle);
|
|
|
| - scoped_refptr<URLRequestContextGetter> request_context =
|
| - tab->tab_contents()->request_context();
|
| - if (!request_context.get())
|
| - request_context = tab->profile()->GetRequestContext();
|
| -
|
| - if (SetCookieForURL(url, value, request_context.get()))
|
| + if (SetCookieForURL(url, value, tab->profile()->GetRequestContext()))
|
| *response_value = 1;
|
| }
|
| }
|
|
|