apt-shell (InstallPackages): do not abort when commit is cancelled (ALT#13877)
Unlike one may suppose, this change will not cause the cache of accumulated changes to be cleared by cancelled "commit" operation, but this is exactly what Vitaly Lipatov has proposed in his comments to ALT#13877.
This commit is contained in:
parent
7f7e8d7b6b
commit
968a2cbf2f
@ -1100,10 +1100,7 @@ bool InstallPackages(CacheFile &Cache,bool ShwKept,bool Ask = true,
|
||||
" ?] "),Prompt);
|
||||
c2out << flush;
|
||||
if (AnalPrompt(Prompt) == false)
|
||||
{
|
||||
c2out << _("Abort.") << endl;
|
||||
exit(1);
|
||||
}
|
||||
return _error->Error(_("Operation cancelled."));
|
||||
}
|
||||
else
|
||||
{
|
||||
@ -1119,10 +1116,7 @@ bool InstallPackages(CacheFile &Cache,bool ShwKept,bool Ask = true,
|
||||
c2out << _("Do you want to continue? [Y/n] ") << flush;
|
||||
|
||||
if (YnPrompt() == false)
|
||||
{
|
||||
c2out << _("Abort.") << endl;
|
||||
exit(1);
|
||||
}
|
||||
return _error->Error(_("Operation cancelled."));
|
||||
}
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user