git/pack: add support for skipping ssh signatures

ssh signatures confused our commit parsing; teach our
commit parsing to skip them.
This commit is contained in:
Ori Bernstein 2022-06-11 17:48:20 +00:00
parent bb33663b40
commit 3e176bd975

View file

@ -884,6 +884,7 @@ parsecommit(Object *o)
}else if(strcmp(buf, "gpgsig") == 0){ }else if(strcmp(buf, "gpgsig") == 0){
/* just drop it */ /* just drop it */
if((t = strstr(p, "-----END PGP SIGNATURE-----")) == nil) if((t = strstr(p, "-----END PGP SIGNATURE-----")) == nil)
if((t = strstr(p, "-----END SSH SIGNATURE-----")) == nil)
sysfatal("malformed gpg signature"); sysfatal("malformed gpg signature");
np -= t - p; np -= t - p;
p = t; p = t;