Ansgar pushed to branch master at Debian FTP Team / dak
Commits:
-
d4383287
by Ansgar at 2022-06-30T20:02:28+02:00
1 changed file:
Changes:
... | ... | @@ -151,7 +151,11 @@ class SignedFile: |
151 | 151 | stderr = self.stderr.decode('ascii', errors='replace')
|
152 | 152 | raise GpgException("No status output from GPG. (GPG exited with status code %s)\n%s" % (exit_code, stderr))
|
153 | 153 | |
154 | - if exit_code not in (0, 1):
|
|
154 | + # gpg exits with 0 (no error), 1 (at least one invalid sig),
|
|
155 | + # or anything else (fatal error). Even though status 2
|
|
156 | + # indicates a fatal error, we still allow it as it is also
|
|
157 | + # returned when the public key is not known.
|
|
158 | + if exit_code not in (0, 1, 2):
|
|
155 | 159 | stderr = self.stderr.decode('ascii', errors='replace')
|
156 | 160 | raise GpgException(f"GPG exited with a fatal error (exit code {exit_code})\n{stderr}")
|
157 | 161 |