Summary: | special chars in URL are escaped (and more) when atom feed is imported from Konq's statusbar | ||
---|---|---|---|
Product: | [Applications] akregator | Reporter: | Stefan Monov <logixoul> |
Component: | akregator konqueror plugin | Assignee: | kdepim bugs <kdepim-bugs> |
Status: | RESOLVED FIXED | ||
Severity: | normal | ||
Priority: | NOR | ||
Version: | 1.2.4 | ||
Target Milestone: | --- | ||
Platform: | openSUSE | ||
OS: | Linux | ||
Latest Commit: | Version Fixed In: |
Description
Stefan Monov
2006-08-20 15:34:01 UTC
Looks like PluginBase::fixRelativeURL does not work as expected. Confirmed. SVN commit 575021 by osterfeld: fix completion of URLs starting with "/", e.g. baseurl=http://foobar.com/feeds, link=/feeds/atom.xml BUG: 132687 M +7 -5 pluginbase.cpp --- branches/KDE/3.5/kdeaddons/konq-plugins/akregator/pluginbase.cpp #575020:575021 @@ -83,19 +83,21 @@ } else if (s2.startsWith("/")) { - u=baseurl; - u.setPath(s2); + KURL b2(baseurl); + b2.setPath(QString()); // delete path and query, so that only protocol://host remains + b2.setQuery(QString()); + u = KURL(b2, s2.remove(0,1)); // remove leading "/" } else { - u=baseurl; - u.addPath(s2); + u = KURL(baseurl, s2); } - u.cleanPath(); } else u=s2; u.cleanPath(); + //kdDebug() << "AKREGATOR_PLUGIN_FIXURL: " << "url=" << s << " baseurl=" << baseurl.url() << " fixed=" << u.url() << +endl; return u.url(); } SVN commit 575024 by osterfeld: forwardport #132687 CCBUG: 132687 M +7 -5 pluginbase.cpp --- trunk/KDE/kdeaddons/konq-plugins/akregator/pluginbase.cpp #575023:575024 @@ -81,19 +81,21 @@ } else if (s2.startsWith("/")) { - u=baseurl; - u.setPath(s2); + KUrl b2(baseurl); + b2.setPath(QString()); // delete path and query, so that only protocol://host remains + b2.setQuery(QString()); + u = KUrl(b2, s2.remove(0,1)); // remove leading "/" } else { - u=baseurl; - u.addPath(s2); + u = KUrl(baseurl, s2); } - u.cleanPath(); } else u=s2; u.cleanPath(); + //kdDebug() << "AKREGATOR_PLUGIN_FIXURL: " << "url=" << s << " baseurl=" << baseurl.url() << " fixed=" << u.url() << +endl; return u.url(); } |