summaryrefslogtreecommitdiffstats
path: root/WebCore/platform/mac/CookieJar.mm
diff options
context:
space:
mode:
Diffstat (limited to 'WebCore/platform/mac/CookieJar.mm')
-rw-r--r--WebCore/platform/mac/CookieJar.mm14
1 files changed, 6 insertions, 8 deletions
diff --git a/WebCore/platform/mac/CookieJar.mm b/WebCore/platform/mac/CookieJar.mm
index 7c288ad..5fe7a63 100644
--- a/WebCore/platform/mac/CookieJar.mm
+++ b/WebCore/platform/mac/CookieJar.mm
@@ -1,5 +1,5 @@
/*
- * Copyright (C) 2003, 2006 Apple Computer, Inc. All rights reserved.
+ * Copyright (C) 2003, 2006, 2008 Apple Inc. All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions
@@ -26,14 +26,12 @@
#import "config.h"
#import "CookieJar.h"
-#import "KURL.h"
#import "BlockExceptions.h"
-#import "PlatformString.h"
-
+#import "KURL.h"
#import <wtf/RetainPtr.h>
#ifdef BUILDING_ON_TIGER
-typedef unsigned int NSUInteger;
+typedef unsigned NSUInteger;
#endif
namespace WebCore {
@@ -42,7 +40,7 @@ String cookies(const Document* /*document*/, const KURL& url)
{
BEGIN_BLOCK_OBJC_EXCEPTIONS;
- NSURL *cookieURL = url.getNSURL();
+ NSURL *cookieURL = url;
NSArray *cookiesForURL = [[NSHTTPCookieStorage sharedHTTPCookieStorage] cookiesForURL:cookieURL];
// <rdar://problem/5632883> On 10.5, NSHTTPCookieStorage would happily store an empty cookie, which would be sent as "Cookie: =".
@@ -70,14 +68,14 @@ void setCookies(Document* /*document*/, const KURL& url, const KURL& policyBaseU
if (cookieStr.isEmpty())
return;
- NSURL *cookieURL = url.getNSURL();
+ NSURL *cookieURL = url;
// <http://bugs.webkit.org/show_bug.cgi?id=6531>, <rdar://4409034>
// cookiesWithResponseHeaderFields doesn't parse cookies without a value
String cookieString = cookieStr.contains('=') ? cookieStr : cookieStr + "=";
NSArray *cookies = [NSHTTPCookie cookiesWithResponseHeaderFields:[NSDictionary dictionaryWithObject:cookieString forKey:@"Set-Cookie"] forURL:cookieURL];
- [[NSHTTPCookieStorage sharedHTTPCookieStorage] setCookies:cookies forURL:cookieURL mainDocumentURL:policyBaseURL.getNSURL()];
+ [[NSHTTPCookieStorage sharedHTTPCookieStorage] setCookies:cookies forURL:cookieURL mainDocumentURL:policyBaseURL];
END_BLOCK_OBJC_EXCEPTIONS;
}