Skip to content
Snippets Groups Projects
Commit 4d34122e authored by Junio C Hamano's avatar Junio C Hamano
Browse files

Merge branch 'jc/gpg-status'

"git verify-tag" and "git verify-commit" have been taught to use
the exit status of underlying "gpg --verify" to signal bad or
untrusted signature they found.

* jc/gpg-status:
  gpg-interface: propagate exit status from gpg back to the callers
parents 6e8f3d1c 4e5dc9ca
No related branches found
No related tags found
No related merge requests found
Loading
Loading
@@ -136,12 +136,13 @@ int check_signature(const char *payload, size_t plen, const char *signature,
sigc->gpg_output = strbuf_detach(&gpg_output, NULL);
sigc->gpg_status = strbuf_detach(&gpg_status, NULL);
parse_gpg_output(sigc);
status |= sigc->result != 'G' && sigc->result != 'U';
 
out:
strbuf_release(&gpg_status);
strbuf_release(&gpg_output);
 
return sigc->result != 'G' && sigc->result != 'U';
return !!status;
}
 
void print_signature_buffer(const struct signature_check *sigc, unsigned flags)
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment