summaryrefslogtreecommitdiffstats
path: root/libtommath
diff options
context:
space:
mode:
authorjan.nijtmans <nijtmans@users.sourceforge.net>2024-03-29 14:22:40 (GMT)
committerjan.nijtmans <nijtmans@users.sourceforge.net>2024-03-29 14:22:40 (GMT)
commit564f0e0e6d6a4d00527e3411759b4b3f37b116b7 (patch)
tree0eeecfcae004f47c111affefc9b5dea723d4fe2b /libtommath
parentae6f158a64b28b8a62cf9788b8ab31018813a111 (diff)
parenta35d237b46438966f228d32c0b48755e853f7446 (diff)
downloadtcl-564f0e0e6d6a4d00527e3411759b4b3f37b116b7.zip
tcl-564f0e0e6d6a4d00527e3411759b4b3f37b116b7.tar.gz
tcl-564f0e0e6d6a4d00527e3411759b4b3f37b116b7.tar.bz2
Merge 8.7
Diffstat (limited to 'libtommath')
-rw-r--r--libtommath/bn_mp_root_n.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/libtommath/bn_mp_root_n.c b/libtommath/bn_mp_root_n.c
index 51ad759..c028ef1 100644
--- a/libtommath/bn_mp_root_n.c
+++ b/libtommath/bn_mp_root_n.c
@@ -18,7 +18,7 @@ mp_err mp_root_n(const mp_int *a, int b, mp_int *c)
int ilog2;
mp_err err;
- if (b < 0 || (unsigned)b > (unsigned)MP_DIGIT_MAX) {
+ if ((unsigned)b > (unsigned)MP_MIN(MP_DIGIT_MAX, INT_MAX)) {
return MP_VAL;
}