Fixed integer overflow warning in gcdext.c.

This commit is contained in:
wbhart 2012-09-28 15:57:37 +00:00
parent e77e27ca6b
commit b0f3391568

View File

@ -235,7 +235,7 @@ mpn_gcdext (mp_ptr gp, mp_ptr up, mp_size_t *usizep,
/* Final mpn_gcdext_lehmer_n call. Need space for u and for /* Final mpn_gcdext_lehmer_n call. Need space for u and for
copies of a and b. */ copies of a and b. */
scratch = MPN_GCDEXT_LEHMER_N_ITCH (GCDEXT_DC_THRESHOLD) scratch = (mp_size_t) MPN_GCDEXT_LEHMER_N_ITCH (GCDEXT_DC_THRESHOLD)
+ 3*GCDEXT_DC_THRESHOLD; + 3*GCDEXT_DC_THRESHOLD;
if (scratch > talloc) if (scratch > talloc)