fix alt_ecc_size exptmod with negative numbers

pull/129/merge
toddouska 2015-08-27 11:18:06 -07:00
parent 1ee27f7a04
commit 5e26a5c8fc
1 changed files with 1 additions and 1 deletions

View File

@ -1209,7 +1209,7 @@ int fp_exptmod(fp_int * G, fp_int * X, fp_int * P, fp_int * Y)
fp_int tmp;
/* yes, copy G and invmod it */
fp_copy(G, &tmp);
fp_init_copy(&tmp, G);
if ((err = fp_invmod(&tmp, P, &tmp)) != FP_OKAY) {
return err;
}