summaryrefslogtreecommitdiff
path: root/apt-pkg/deb
diff options
context:
space:
mode:
Diffstat (limited to 'apt-pkg/deb')
-rw-r--r--apt-pkg/deb/deblistparser.h3
-rw-r--r--apt-pkg/deb/dpkgpm.cc24
2 files changed, 9 insertions, 18 deletions
diff --git a/apt-pkg/deb/deblistparser.h b/apt-pkg/deb/deblistparser.h
index 286244cc9..baace79fe 100644
--- a/apt-pkg/deb/deblistparser.h
+++ b/apt-pkg/deb/deblistparser.h
@@ -15,6 +15,7 @@
#include <apt-pkg/tagfile.h>
#include <apt-pkg/md5.h>
#include <apt-pkg/pkgcache.h>
+#include <apt-pkg/macros.h>
#include <string>
#include <vector>
@@ -102,7 +103,7 @@ class debListParser : public pkgCacheGenerator::ListParser
virtual ~debListParser() {};
private:
- unsigned char ParseMultiArch(bool const showErrors);
+ APT_HIDDEN unsigned char ParseMultiArch(bool const showErrors);
};
#endif
diff --git a/apt-pkg/deb/dpkgpm.cc b/apt-pkg/deb/dpkgpm.cc
index 9fee7c923..5a5fff13b 100644
--- a/apt-pkg/deb/dpkgpm.cc
+++ b/apt-pkg/deb/dpkgpm.cc
@@ -1530,28 +1530,18 @@ bool pkgDPkgPM::GoNoABIBreak(APT::Progress::PackageManager *progress)
// here but keep the loop going and just report it as a error
// for later
bool const stopOnError = _config->FindB("Dpkg::StopOnError",true);
-
- if(stopOnError)
- RunScripts("DPkg::Post-Invoke");
- if (WIFSIGNALED(Status) != 0 && WTERMSIG(Status) == SIGSEGV)
+ if (WIFSIGNALED(Status) != 0 && WTERMSIG(Status) == SIGSEGV)
strprintf(d->dpkg_error, "Sub-process %s received a segmentation fault.",Args[0]);
else if (WIFEXITED(Status) != 0)
strprintf(d->dpkg_error, "Sub-process %s returned an error code (%u)",Args[0],WEXITSTATUS(Status));
- else
+ else
strprintf(d->dpkg_error, "Sub-process %s exited unexpectedly",Args[0]);
+ _error->Error("%s", d->dpkg_error.c_str());
- if(d->dpkg_error.size() > 0)
- _error->Error("%s", d->dpkg_error.c_str());
-
- if(stopOnError)
- {
- CloseLog();
- StopPtyMagic();
- d->progress->Stop();
- return false;
- }
- }
+ if(stopOnError)
+ break;
+ }
}
// dpkg is done at this point
d->progress->Stop();
@@ -1582,7 +1572,7 @@ bool pkgDPkgPM::GoNoABIBreak(APT::Progress::PackageManager *progress)
}
Cache.writeStateFile(NULL);
- return true;
+ return d->dpkg_error.empty();
}
void SigINT(int /*sig*/) {