summaryrefslogtreecommitdiffstats
path: root/net/base/cookie_monster.cc
diff options
context:
space:
mode:
Diffstat (limited to 'net/base/cookie_monster.cc')
-rw-r--r--net/base/cookie_monster.cc14
1 files changed, 14 insertions, 0 deletions
diff --git a/net/base/cookie_monster.cc b/net/base/cookie_monster.cc
index 1b37f48..50ffcac 100644
--- a/net/base/cookie_monster.cc
+++ b/net/base/cookie_monster.cc
@@ -1254,6 +1254,20 @@ std::string CookieMonster::ParsedCookie::DebugString() const {
return out;
}
+CookieMonster::CanonicalCookie::CanonicalCookie(const GURL& url,
+ const ParsedCookie& pc)
+ : name_(pc.Name()),
+ value_(pc.Value()),
+ path_(CanonPath(url, pc)),
+ creation_date_(Time::Now()),
+ last_access_date_(Time()),
+ has_expires_(pc.HasExpires()),
+ secure_(pc.IsSecure()),
+ httponly_(pc.IsHttpOnly()) {
+ if (has_expires_)
+ expiry_date_ = CanonExpiration(pc, creation_date_, CookieOptions());
+}
+
bool CookieMonster::CanonicalCookie::IsOnPath(
const std::string& url_path) const {