apt/apt-0.5.15cnc6-alt-apt-shell-dl.patch
Sergey Bolshakov a8de0fe5ed 0.5.15cnc6-alt13
- apt-shell: possible fix of #4707 (rider@)
2005-06-16 11:25:49 +00:00

26 lines
778 B
Diff

--- apt-0.5.15cnc6/cmdline/apt-shell.cc..segfault 2005-06-16 15:11:44 +0400
+++ apt-0.5.15cnc6/cmdline/apt-shell.cc 2005-06-16 15:17:59 +0400
@@ -145,8 +145,11 @@
{
if (Guarded) {
delete *Cache;
+ if (_error->PendingError())
+ _error->PushState();
*Cache = new CacheFile;
(*Cache)->Open();
+ _error->PopState();
if ((*Cache)->CheckDeps(true) == false) {
c1out << _("There are broken packages. ")
<< _("Run `check' to see them.") << endl;
@@ -4058,7 +4061,9 @@
_error->Error(_("You have no permissions for that"));
return false;
}
- return InstallPackages(*GCache,false);
+ int err = InstallPackages(*GCache,false);
+ _config->Set("APT::Get::Fix-Broken",false);
+ return err;
}
bool DoStatus(CommandLine &CmdL)