Summary: | Field 'Execute' field is considered mandatory in Konsole 3.5.0-beta1 configuration, tab 'Session' | ||
---|---|---|---|
Product: | [Applications] konsole | Reporter: | Ernst de Haan <ernst.dehaan> |
Component: | general | Assignee: | Konsole Developer <konsole-devel> |
Status: | RESOLVED FIXED | ||
Severity: | normal | ||
Priority: | NOR | ||
Version: | 1.6 | ||
Target Milestone: | --- | ||
Platform: | unspecified | ||
OS: | Linux | ||
Latest Commit: | Version Fixed In: | ||
Sentry Crash Report: | |||
Attachments: | Screenshot of warning message |
Description
Ernst de Haan
2005-09-28 16:42:38 UTC
Created attachment 12752 [details]
Screenshot of warning message
The warning was done to fix http://bugs.kde.org/show_bug.cgi?id=105754. Perhaps if the Execute field is empty automatically add /bin/sh? Well, if the Execute field is empty, then no check should have to be done. Because in that case the default command will be executed, which is the shell. And that is -depending on the user's settings- not /bin/sh, but could be /bin/bash or /usr/local/bin/tcsh, for example. So proposed change in behaviour: If the Execute field is empty, then do not perform the check that triggered the warning shown in the screenshot. SVN commit 464922 by hindenburg: If Execute field empty, don't display warning about invalid Execute entry. BUG: 113515 M +11 -11 sessioneditor.cpp --- branches/KDE/3.5/kdebase/kcontrol/konsole/sessioneditor.cpp #464921:464922 @@ -290,22 +290,22 @@ // Verify Execute entry is valid; otherwise Konsole will ignore it. // This code is take from konsole.cpp; if you change one, change both. QString exec = executeLine->text(); - if ( exec.startsWith( "su -c \'" ) ) { - exec = exec.mid( 7, exec.length() - 8 ); - } - exec = KRun::binaryName( exec, false ); - exec = KShell::tildeExpand( exec ); - QString pexec = KGlobal::dirs()->findExe( exec ); + if ( !exec.isEmpty() ) // If Execute field is empty, default shell is used. + { + if ( exec.startsWith( "su -c \'" ) ) + exec = exec.mid( 7, exec.length() - 8 ); + exec = KRun::binaryName( exec, false ); + exec = KShell::tildeExpand( exec ); + QString pexec = KGlobal::dirs()->findExe( exec ); - if ( pexec.isEmpty() ) - { - int result = KMessageBox::warningContinueCancel( this, + if ( pexec.isEmpty() ) + { + int result = KMessageBox::warningContinueCancel( this, i18n( "The Execute entry is not a valid command.\n" "You can still save this session, but it will not show up in Konsole's Session list." ), i18n( "Invalid Execute Entry" ), KStdGuiItem::save() ); - if ( result != KMessageBox::Continue ) - { + if ( result != KMessageBox::Continue ) return; } Cheers! |