summaryrefslogtreecommitdiffstats
path: root/arith.c
diff options
context:
space:
mode:
Diffstat (limited to 'arith.c')
-rw-r--r--arith.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/arith.c b/arith.c
index 401e9693..8ba7fd21 100644
--- a/arith.c
+++ b/arith.c
@@ -2934,7 +2934,9 @@ val logcount(val n)
}
case BGNUM:
{
- mp_size co = mp_count_ones(mp(n));
+ mp_err co = mp_count_ones(mp(n));
+ if (co < 0)
+ internal_error("problem in bignum arithmetic");
return unum(co);
}
default: