ALT Linux Bugzilla
– Attachment 3182 Details for
Bug 18343
Сделать выход по ^D из apt-shell
New bug
|
Search
|
[?]
|
Help
Register
|
Log In
[x]
|
Forgot Password
Login:
[x]
|
EN
|
RU
[patch]
add feedback to Ctrl-D
apt-0.5.15lorg2-alt-apt-shell_quit_by_ctrld.patch (text/plain), 759 bytes, created by
Ivan A. Melnikov
on 2009-01-03 16:04:14 MSK
(
hide
)
Description:
add feedback to Ctrl-D
Filename:
MIME Type:
Creator:
Ivan A. Melnikov
Created:
2009-01-03 16:04:14 MSK
Size:
759 bytes
patch
obsolete
> >https://bugzilla.altlinux.org/show_bug.cgi?id=18343 > >diff --git a/apt/cmdline/apt-shell.cc b/apt/cmdline/apt-shell.cc >index 6d1f767..ff4fd2d 100644 >--- a/apt/cmdline/apt-shell.cc >+++ b/apt/cmdline/apt-shell.cc >@@ -4477,10 +4477,18 @@ int main(int argc,const char *argv[]) > } > > line = readline(_config->Find("APT::Shell::Prompt", "apt> ").c_str()); >- if (!line || !*line) { >- free(line); >- continue; >+ if (!line) { >+ // exit from shell by Ctrl-D >+ c1out << "quit" << endl; >+ _config->Set("quit", "true"); >+ continue; >+ } >+ >+ if (!*line) { >+ free(line); >+ continue; > } >+ > add_history(line); > > largc = 1; // CommandLine.Parse() ignores the first option.
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
Attachments on
bug 18343
: 3182