diff options
author | Michael Vogt <egon@debian-devbox> | 2011-07-13 19:02:10 +0200 |
---|---|---|
committer | Michael Vogt <egon@debian-devbox> | 2011-07-13 19:02:10 +0200 |
commit | 89c4c588b275d098af33f36eeddea6fd75068342 (patch) | |
tree | 1e8cf8d8ab9651618d76f40c4eae97501e427eb7 /methods/gpgv.cc | |
parent | 15fb00074cb5757e4cdcd790fcf75f0134ae0fe4 (diff) |
fix from David Kalnischkies for the InRelease gpg verification
code (LP: #784473)
Diffstat (limited to 'methods/gpgv.cc')
-rw-r--r-- | methods/gpgv.cc | 13 |
1 files changed, 8 insertions, 5 deletions
diff --git a/methods/gpgv.cc b/methods/gpgv.cc index efe1f73f7..960c06180 100644 --- a/methods/gpgv.cc +++ b/methods/gpgv.cc @@ -65,13 +65,16 @@ string GPGVMethod::VerifyGetSigners(const char *file, const char *outfile, return string("Couldn't spawn new process") + strerror(errno); else if (pid == 0) { - if (SigVerify::RunGPGV(outfile, file, 3, fd) == false) + _error->PushToStack(); + bool const success = SigVerify::RunGPGV(outfile, file, 3, fd); + if (success == false) { - // TRANSLATOR: %s is the trusted keyring parts directory - ioprintf(ret, _("No keyring installed in %s."), - _config->FindDir("Dir::Etc::TrustedParts").c_str()); - return ret.str(); + string errmsg; + _error->PopMessage(errmsg); + _error->RevertToStack(); + return errmsg; } + _error->RevertToStack(); exit(111); } close(fd[1]); |