aboutsummaryrefslogtreecommitdiff
path: root/x11/kdelibs4
diff options
context:
space:
mode:
authorMichael Nottebrock <lofi@FreeBSD.org>2007-09-19 16:44:37 +0000
committerMichael Nottebrock <lofi@FreeBSD.org>2007-09-19 16:44:37 +0000
commit8e352eea26ed57b8aad0c1dc5d0e753d8a2aa115 (patch)
tree62b313d6f93ca7597c6eb83d2472e612ba0cbea8 /x11/kdelibs4
parent78c02ac4fa95875310585892282e1eb032925d66 (diff)
downloadports-8e352eea26ed57b8aad0c1dc5d0e753d8a2aa115.tar.gz
ports-8e352eea26ed57b8aad0c1dc5d0e753d8a2aa115.zip
Notes
Diffstat (limited to 'x11/kdelibs4')
-rw-r--r--x11/kdelibs4/Makefile2
-rw-r--r--x11/kdelibs4/files/patch-post-3.5.7-kdelibs-kdecore-2.diff34
-rw-r--r--x11/kdelibs4/files/patch-post-3.5.7-kdelibs-kdecore.diff61
3 files changed, 35 insertions, 62 deletions
diff --git a/x11/kdelibs4/Makefile b/x11/kdelibs4/Makefile
index 02510f68f92b..9bc6bcc02649 100644
--- a/x11/kdelibs4/Makefile
+++ b/x11/kdelibs4/Makefile
@@ -8,7 +8,7 @@
PORTNAME= kdelibs
PORTVERSION= ${KDE_VERSION}
-PORTREVISION= 1
+PORTREVISION= 2
CATEGORIES= x11 kde ipv6
MASTER_SITES= ${MASTER_SITE_KDE}
MASTER_SITE_SUBDIR= stable/${PORTVERSION:S/.0//}/src
diff --git a/x11/kdelibs4/files/patch-post-3.5.7-kdelibs-kdecore-2.diff b/x11/kdelibs4/files/patch-post-3.5.7-kdelibs-kdecore-2.diff
new file mode 100644
index 000000000000..50a9ed17e1dc
--- /dev/null
+++ b/x11/kdelibs4/files/patch-post-3.5.7-kdelibs-kdecore-2.diff
@@ -0,0 +1,34 @@
+--- kdecore/kurl.cpp
++++ kdecore/kurl.cpp
+@@ -30,6 +30,7 @@
+ #include <kglobal.h>
+ #include <kidna.h>
+ #include <kprotocolinfo.h>
++#include <kstringhandler.h>
+ #endif
+
+ #include <stdio.h>
+@@ -183,7 +184,7 @@ static QString lazy_encode( const QStrin
+ (character == '?') || // Start of query delimiter
+ ((character == '@') && encodeAt) || // Username delimiter
+ (character == '#') || // Start of reference delimiter
+- ((character == 32) && (i+1 == old_length))) // A trailing space
++ ((character == 32) && (i+1 == old_length || segment[i+1] == ' '))) // A trailing space
+ {
+ new_segment[ new_length++ ] = '%';
+
+@@ -1540,7 +1541,13 @@ QString KURL::prettyURL( int _trailing )
+ u += "//";
+ if ( hasUser() )
+ {
+- u += lazy_encode(m_strUser);
++ QString s = m_strUser;
++#ifndef KDE_QT_ONLY
++ // shorten the username, its unlikely to be valid without password anyway
++ if (!hasPass())
++ s = KStringHandler::csqueeze(s, 16);
++#endif
++ u += encode(s, 0, 0);
+ // Don't show password!
+ u += "@";
+ }
diff --git a/x11/kdelibs4/files/patch-post-3.5.7-kdelibs-kdecore.diff b/x11/kdelibs4/files/patch-post-3.5.7-kdelibs-kdecore.diff
deleted file mode 100644
index eb7e89e13579..000000000000
--- a/x11/kdelibs4/files/patch-post-3.5.7-kdelibs-kdecore.diff
+++ /dev/null
@@ -1,61 +0,0 @@
-------------------------------------------------------------------------
-r700053 | mueller | 2007-08-14 18:37:30 +0200 (Tue, 14 Aug 2007) | 2 lines
-
-be more robust against addressbar spoofing (CVE-2007-4225)
-
-------------------------------------------------------------------------
---- kdecore/tests/kurltest.cpp
-+++ kdecore/tests/kurltest.cpp
-@@ -288,6 +288,16 @@ int main(int argc, char *argv[])
- check("KURL::prettyURL()", url15582.prettyURL(), "http://alain.knaff.linux.lu/bug-reports/kde/percentage%in%url.html");
- check("KURL::url()", url15582.url(), "http://alain.knaff.linux.lu/bug-reports/kde/percentage%25in%25url.html");
-
-+ KURL whitespaceInUser("http://www.google.com%20%20%20%20%20@foobar.com/");
-+ check("KURL::prettyURL()", whitespaceInUser.prettyURL(), "http://www.google.com%20%20%20%20%20@foobar.com/");
-+
-+ KURL whitespaceInPath("http://www.google.com/foo%20bar/");
-+ check("KURL::prettyURL()", whitespaceInPath.prettyURL(), "http://www.google.com/foo bar/");
-+
-+ KURL whitespaceInPath2("http://www.google.com/foo%20%20%20%20%20%20%20bar/");
-+ check("KURL::prettyURL()", whitespaceInPath2.prettyURL(),
-+ "http://www.google.com/foo%20%20%20%20%20%20 bar/");
-+
- KURL carsten;
- carsten.setPath("/home/gis/src/kde/kdelibs/kfile/.#kfiledetailview.cpp.1.18");
- check("KURL::path()", carsten.path(), "/home/gis/src/kde/kdelibs/kfile/.#kfiledetailview.cpp.1.18");
-@@ -594,6 +604,15 @@ int main(int argc, char *argv[])
- check("http: URL with empty path string path", waba1.path(),
- "");
-
-+ waba1 = "http://www.meinestadt.de&url_plain=http";
-+ check("http: URL with empty path string", waba1.host(),
-+ "www.meinestadt.de&url_plain=http");
-+ check("http: URL with empty path string", waba1.htmlURL(),
-+ "http://www.meinestadt.de&amp;url_plain=http");
-+
-+ check("http: URL with empty path string", waba1.path(),
-+ "");
-+
- waba1 = "http://a:389#b=c";
- check( "http: URL with port, ref, and empty path; url", waba1.url(), "http://a:389#b=c" );
- check( "http: URL with port, ref, and empty path; host", waba1.host(), "a" );
---- kdecore/kurl.cpp
-+++ kdecore/kurl.cpp
-@@ -183,7 +183,7 @@ static QString lazy_encode( const QStrin
- (character == '?') || // Start of query delimiter
- ((character == '@') && encodeAt) || // Username delimiter
- (character == '#') || // Start of reference delimiter
-- ((character == 32) && (i+1 == old_length))) // A trailing space
-+ ((character == 32) && (i+1 == old_length || segment[i+1] == ' '))) // A trailing space
- {
- new_segment[ new_length++ ] = '%';
-
-@@ -1540,7 +1540,7 @@ QString KURL::prettyURL( int _trailing )
- u += "//";
- if ( hasUser() )
- {
-- u += lazy_encode(m_strUser);
-+ u += encode(m_strUser, 0, 0);
- // Don't show password!
- u += "@";
- }