X-Git-Url: https://the.earth.li/gitweb/?a=blobdiff_plain;f=sigcheck.c;h=2c1fc4c0871adc3bde0b5de10db26c7a57cd0b65;hb=c0fee41b459cc3822d890bac98882a6c9696c033;hp=29ab652e71dda830273b4f45c1bd994094ece9e0;hpb=e82fd57b92d94287f728e37a3e17aaab11b722b8;p=onak.git diff --git a/sigcheck.c b/sigcheck.c index 29ab652..2c1fc4c 100644 --- a/sigcheck.c +++ b/sigcheck.c @@ -263,6 +263,12 @@ static onak_status_t onak_parse_key_material(struct openpgp_packet *pk, return ONAK_E_UNSUPPORTED_FEATURE; } + /* + * Keep scan-build happy; we bump this in MPI_TO_MPZ and then don't use + * it again the last time we do so. + */ + (void)ofs; + key->type = pk->data[5]; if (ret != ONAK_E_OK) { @@ -311,7 +317,7 @@ onak_status_t onak_check_hash_sig(struct openpgp_publickey *sigkey, } /* Skip to the signature material */ - ofs += 19; + ofs = 19; sigkeytype = sig->data[15]; } else if (sig->data[0] >= 4) { /* Skip the hashed data */