[SCM] WebKit Debian packaging branch, webkit-1.1, updated. upstream/1.1.20-204-g221d8e8
christian at webkit.org
christian at webkit.org
Wed Feb 10 22:14:53 UTC 2010
The following commit has been merged in the webkit-1.1 branch:
commit 1ac63bd81c45bdc8c202d86a2db059045bfaf720
Author: christian at webkit.org <christian at webkit.org@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Date: Thu Feb 4 22:51:12 2010 +0000
2010-02-04 Christian Dywan <christian at twotasts.de>
Reviewed by Xan Lopez.
Require either libsoup 2.28.2 or 2.29.90.
* configure.ac:
2010-02-04 Christian Dywan <christian at twotoasts.de>
Reviewed by Xan Lopez.
Conditionalize third party cookie policy for libsoup 2.29.90.
* platform/network/soup/CookieJarSoup.cpp:
(WebCore::setCookies):
* platform/network/soup/DNSSoup.cpp:
(WebCore::prefetchDNS):
* platform/network/soup/ResourceHandleSoup.cpp:
(WebCore::restartedCallback):
(WebCore::startHttp):
* platform/network/soup/ResourceRequestSoup.cpp:
(WebCore::ResourceRequest::toSoupMessage):
(WebCore::ResourceRequest::updateFromSoupMessage):
git-svn-id: http://svn.webkit.org/repository/webkit/trunk@54375 268f45cc-cd09-0410-ab3c-d52691b4dbfc
diff --git a/ChangeLog b/ChangeLog
index 23995e0..c57e5e0 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,11 @@
+2010-02-04 Christian Dywan <christian at twotasts.de>
+
+ Reviewed by Xan Lopez.
+
+ Require either libsoup 2.28.2 or 2.29.90.
+
+ * configure.ac:
+
2010-02-04 Xan Lopez <xlopez at igalia.com>
Reviewed by Gustavo Noronha.
diff --git a/WebCore/ChangeLog b/WebCore/ChangeLog
index 43698cd..6d0ca0b 100644
--- a/WebCore/ChangeLog
+++ b/WebCore/ChangeLog
@@ -1,5 +1,22 @@
2010-02-04 Christian Dywan <christian at twotoasts.de>
+ Reviewed by Xan Lopez.
+
+ Conditionalize third party cookie policy for libsoup 2.29.90.
+
+ * platform/network/soup/CookieJarSoup.cpp:
+ (WebCore::setCookies):
+ * platform/network/soup/DNSSoup.cpp:
+ (WebCore::prefetchDNS):
+ * platform/network/soup/ResourceHandleSoup.cpp:
+ (WebCore::restartedCallback):
+ (WebCore::startHttp):
+ * platform/network/soup/ResourceRequestSoup.cpp:
+ (WebCore::ResourceRequest::toSoupMessage):
+ (WebCore::ResourceRequest::updateFromSoupMessage):
+
+2010-02-04 Christian Dywan <christian at twotoasts.de>
+
Rubber-stamped by Gustavo Noronha Silva.
Add ENABLE(VIDEO) guards around freeOwnedGPtr<GstElement> implementation.
diff --git a/WebCore/platform/network/soup/CookieJarSoup.cpp b/WebCore/platform/network/soup/CookieJarSoup.cpp
index 6f4cc2b..04becf5 100644
--- a/WebCore/platform/network/soup/CookieJarSoup.cpp
+++ b/WebCore/platform/network/soup/CookieJarSoup.cpp
@@ -62,12 +62,19 @@ void setCookies(Document* document, const KURL& url, const String& value)
return;
GOwnPtr<SoupURI> origin(soup_uri_new(url.string().utf8().data()));
+
+#ifdef HAVE_LIBSOUP_2_29_90
GOwnPtr<SoupURI> firstParty(soup_uri_new(document->firstPartyForCookies().string().utf8().data()));
soup_cookie_jar_set_cookie_with_first_party(jar,
origin.get(),
firstParty.get(),
value.utf8().data());
+#else
+ soup_cookie_jar_set_cookie(jar,
+ origin.get(),
+ value.utf8().data());
+#endif
}
String cookies(const Document* /*document*/, const KURL& url)
diff --git a/WebCore/platform/network/soup/DNSSoup.cpp b/WebCore/platform/network/soup/DNSSoup.cpp
index df0d20a..7f47efd 100644
--- a/WebCore/platform/network/soup/DNSSoup.cpp
+++ b/WebCore/platform/network/soup/DNSSoup.cpp
@@ -35,7 +35,7 @@ namespace WebCore {
void prefetchDNS(const String& hostname)
{
-#ifdef HAVE_LIBSOUP_2_29_3
+#ifdef HAVE_LIBSOUP_2_29_90
String uri = "http://"+hostname;
GOwnPtr<SoupURI> soupURI(soup_uri_new(uri.utf8().data()));
// We may get invalid hostnames, so NULL-check here.
diff --git a/WebCore/platform/network/soup/ResourceHandleSoup.cpp b/WebCore/platform/network/soup/ResourceHandleSoup.cpp
index 7862191..ee8e7aa 100644
--- a/WebCore/platform/network/soup/ResourceHandleSoup.cpp
+++ b/WebCore/platform/network/soup/ResourceHandleSoup.cpp
@@ -211,12 +211,14 @@ static void restartedCallback(SoupMessage* msg, gpointer data)
if (d->client())
d->client()->willSendRequest(handle, request, response);
+#ifdef HAVE_LIBSOUP_2_29_90
// Update the first party in case the base URL changed with the redirect
String firstPartyString = request.firstPartyForCookies().string();
if (!firstPartyString.isEmpty()) {
GOwnPtr<SoupURI> firstParty(soup_uri_new(firstPartyString.utf8().data()));
soup_message_set_first_party(d->m_msg, firstParty.get());
}
+#endif
}
static void gotHeadersCallback(SoupMessage* msg, gpointer data)
@@ -492,11 +494,13 @@ static bool startHttp(ResourceHandle* handle)
g_signal_connect(d->m_msg, "content-sniffed", G_CALLBACK(contentSniffedCallback), handle);
g_signal_connect(d->m_msg, "got-chunk", G_CALLBACK(gotChunkCallback), handle);
+#ifdef HAVE_LIBSOUP_2_29_90
String firstPartyString = request.firstPartyForCookies().string();
if (!firstPartyString.isEmpty()) {
GOwnPtr<SoupURI> firstParty(soup_uri_new(firstPartyString.utf8().data()));
soup_message_set_first_party(d->m_msg, firstParty.get());
}
+#endif
g_object_set_data(G_OBJECT(d->m_msg), "resourceHandle", reinterpret_cast<void*>(handle));
FormData* httpBody = d->m_request.httpBody();
diff --git a/WebCore/platform/network/soup/ResourceRequestSoup.cpp b/WebCore/platform/network/soup/ResourceRequestSoup.cpp
index bf289e3..d2c46a6 100644
--- a/WebCore/platform/network/soup/ResourceRequestSoup.cpp
+++ b/WebCore/platform/network/soup/ResourceRequestSoup.cpp
@@ -45,11 +45,13 @@ SoupMessage* ResourceRequest::toSoupMessage() const
soup_message_headers_append(soupHeaders, it->first.string().utf8().data(), it->second.utf8().data());
}
+#ifdef HAVE_LIBSOUP_2_29_90
String firstPartyString = firstPartyForCookies().string();
if (!firstPartyString.isEmpty()) {
GOwnPtr<SoupURI> firstParty(soup_uri_new(firstPartyString.utf8().data()));
soup_message_set_first_party(soupMessage, firstParty.get());
}
+#endif
// Body data is only handled at ResourceHandleSoup::startHttp for
// now; this is because this may not be a good place to go
@@ -76,11 +78,13 @@ void ResourceRequest::updateFromSoupMessage(SoupMessage* soupMessage)
if (soupMessage->request_body->data)
m_httpBody = FormData::create(soupMessage->request_body->data, soupMessage->request_body->length);
+#ifdef HAVE_LIBSOUP_2_29_90
SoupURI* firstParty = soup_message_get_first_party(soupMessage);
if (firstParty) {
GOwnPtr<gchar> firstPartyURI(soup_uri_to_string(firstParty, FALSE));
m_firstPartyForCookies = KURL(KURL(), String::fromUTF8(firstPartyURI.get()));
}
+#endif
// FIXME: m_allowCookies should probably be handled here and on
// doUpdatePlatformRequest somehow.
diff --git a/configure.ac b/configure.ac
index 56a3963..600d635 100644
--- a/configure.ac
+++ b/configure.ac
@@ -190,7 +190,7 @@ if test "$with_hildon" = "yes"; then
fi
# minimum base dependencies
-LIBSOUP_REQUIRED_VERSION=2.29.90
+LIBSOUP_REQUIRED_VERSION=2.28.2
CAIRO_REQUIRED_VERSION=1.6
FONTCONFIG_REQUIRED_VERSION=2.4
FREETYPE2_REQUIRED_VERSION=9.0
@@ -643,13 +643,13 @@ PKG_CHECK_MODULES([LIBSOUP],
AC_SUBST([LIBSOUP_CFLAGS])
AC_SUBST([LIBSOUP_LIBS])
-# check if we can use libSoup 2.29.3 features
-PKG_CHECK_MODULES([LIBSOUP_2_29_3],
- [libsoup-2.4 >= 2.29.3],
- [have_libsoup_2_29_3=yes],
- [have_libsoup_2_29_3=no])
-if test "$have_libsoup_2_29_3" = "yes"; then
- AC_DEFINE([HAVE_LIBSOUP_2_29_3], 1, [Whether libSoup 2.29.3 features are available])
+# check if we can use libSoup 2.29.90 features
+PKG_CHECK_MODULES([LIBSOUP_2_29_90],
+ [libsoup-2.4 >= 2.29.90],
+ [have_libsoup_2_29_90=yes],
+ [have_libsoup_2_29_90=no])
+if test "$have_libsoup_2_29_90" = "yes"; then
+ AC_DEFINE([HAVE_LIBSOUP_2_29_90], 1, [Whether libSoup 2.29.90 features are available])
fi
# check if FreeType/FontConfig are available
--
WebKit Debian packaging
More information about the Pkg-webkit-commits
mailing list