Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(8634)

Unified Diff: chrome_frame/chrome_frame_activex_base.h

Issue 521072: Attempt 2 at landing this.... (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: '' Created 10 years, 11 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « chrome_frame/chrome_frame.gyp ('k') | chrome_frame/chrome_frame_npapi.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome_frame/chrome_frame_activex_base.h
===================================================================
--- chrome_frame/chrome_frame_activex_base.h (revision 35771)
+++ chrome_frame/chrome_frame_activex_base.h (working copy)
@@ -42,6 +42,7 @@
#include "chrome_frame/com_type_info_holder.h"
#include "chrome_frame/urlmon_url_request.h"
#include "grit/generated_resources.h"
+#include "net/base/cookie_monster.h"
// Include without path to make GYP build see it.
#include "chrome_tab.h" // NOLINT
@@ -523,10 +524,17 @@
const std::string& cookie) {
std::string name;
std::string data;
+
size_t name_end = cookie.find('=');
if (std::string::npos != name_end) {
- name = cookie.substr(0, name_end);
- data = cookie.substr(name_end + 1);
+ net::CookieMonster::ParsedCookie parsed_cookie = cookie;
+ name = parsed_cookie.Name();
+ // Verify if the cookie is being deleted. The cookie format is as below
+ // value[; expires=date][; domain=domain][; path=path][; secure]
+ // If the first semicolon appears immediately after the name= string,
+ // it means that the cookie is being deleted.
+ if (!parsed_cookie.Value().empty())
+ data = cookie.substr(name_end + 1);
} else {
data = cookie;
}
« no previous file with comments | « chrome_frame/chrome_frame.gyp ('k') | chrome_frame/chrome_frame_npapi.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698