- include experimental libtool patches * Mon Jun 11 2007 Rex Dieter <rdieter[AT]fedoraproject.org> - 6:3.5.7-2 - kdesu: sudo support (kde bug #20914), Requires(hint): sudo * Wed Jun 06 2007 Than Ngo <than@redhat.com> - 6:3.5.7-0.1.fc7 - 3.5.7
37 lines
1.1 KiB
Diff
37 lines
1.1 KiB
Diff
Index: kdecore/kcmdlineargs.cpp
|
|
===================================================================
|
|
--- kdecore/kcmdlineargs.cpp (Revision 669593)
|
|
+++ kdecore/kcmdlineargs.cpp (Revision 669594)
|
|
@@ -1248,21 +1248,22 @@
|
|
|
|
KURL KCmdLineArgs::makeURL(const char *_urlArg)
|
|
{
|
|
- QString urlArg = QFile::decodeName(_urlArg);
|
|
- if (!QDir::isRelativePath(urlArg))
|
|
- {
|
|
+ const QString urlArg = QFile::decodeName(_urlArg);
|
|
+ QFileInfo fileInfo(urlArg);
|
|
+ if (!fileInfo.isRelative()) { // i.e. starts with '/', on unix
|
|
KURL result;
|
|
result.setPath(urlArg);
|
|
return result; // Absolute path.
|
|
}
|
|
|
|
- if ( !KURL::isRelativeURL(urlArg) )
|
|
- return KURL(urlArg); // Argument is a URL
|
|
+ if ( KURL::isRelativeURL(urlArg) || fileInfo.exists() ) {
|
|
+ KURL result;
|
|
+ result.setPath( cwd()+'/'+urlArg );
|
|
+ result.cleanPath();
|
|
+ return result; // Relative path
|
|
+ }
|
|
|
|
- KURL result;
|
|
- result.setPath( cwd()+"/"+urlArg );
|
|
- result.cleanPath();
|
|
- return result; // Relative path
|
|
+ return KURL(urlArg); // Argument is a URL
|
|
}
|
|
|
|
void
|