Commit 402412fd authored by Dirk Mueller's avatar Dirk Mueller
Browse files

fix shell quoting

svn path=/trunk/KDE/kdebase/apps/konsole/; revision=678405
parent 343becbf
......@@ -262,9 +262,7 @@ void SessionController::openUrl( const KUrl& url )
if ( url.isLocalFile() )
{
QString path = url.toLocalFile();
KShell::quoteArg(path);
_session->emulation()->sendText("cd " + path + '\r');
_session->emulation()->sendText("cd " + KShell::quoteArg(path) + '\r');
}
else if ( url.protocol() == "ssh" )
{
......
......@@ -2665,7 +2665,7 @@ void TerminalDisplay::dropEvent(QDropEvent* event)
_lnAction->setEnabled( false );
}
if (urllist.count()>1)
KShell::quoteArg(tmp);
tmp = KShell::quoteArg(tmp);
_dropText += tmp;
}
......@@ -2696,7 +2696,7 @@ void TerminalDisplay::drop_menu_activated(QAction* action)
{
case paste:
if (_dndFileCount==1)
KShell::quoteArg(_dropText);
_dropText = KShell::quoteArg(_dropText);
emit sendStringToEmu(_dropText.toLocal8Bit());
activateWindow();
break;
......@@ -2712,7 +2712,7 @@ void TerminalDisplay::drop_menu_activated(QAction* action)
_dropText = url.directory( KUrl::ObeyTrailingSlash ); // remove filename
}
}
KShell::quoteArg(_dropText);
_dropText = KShell::quoteArg(_dropText);
emit sendStringToEmu(_dropText.toLocal8Bit());
emit sendStringToEmu("\n");
activateWindow();
......@@ -2729,7 +2729,7 @@ void TerminalDisplay::drop_menu_activated(QAction* action)
}
if (item>cd && item<=mv) {
if (_dndFileCount==1)
KShell::quoteArg(_dropText);
_dropText = KShell::quoteArg(_dropText);
emit sendStringToEmu(_dropText.toLocal8Bit());
emit sendStringToEmu(" .\n");
activateWindow();
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment