diff options
author | Darren Tucker <dtucker@cvs.openbsd.org> | 2022-03-11 09:05:00 +0000 |
---|---|---|
committer | Darren Tucker <dtucker@cvs.openbsd.org> | 2022-03-11 09:05:00 +0000 |
commit | bacfd904f83efe552be78155fc3613147d8023dc (patch) | |
tree | 64d57b44e2e6a65eab8f750eeb589fb96bc0e9b0 | |
parent | a6198ab61e76eeb50abec022df4aa88caa8e35d8 (diff) |
Revert previous commit. The problem it was attempting to fix was already
fixed by tb@ in rev 1.20. Spotted by tb@
-rw-r--r-- | lib/libutil/fmt_scaled.c | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/lib/libutil/fmt_scaled.c b/lib/libutil/fmt_scaled.c index 0b443d4d83a..374901ffe1e 100644 --- a/lib/libutil/fmt_scaled.c +++ b/lib/libutil/fmt_scaled.c @@ -1,4 +1,4 @@ -/* $OpenBSD: fmt_scaled.c,v 1.21 2022/03/11 07:29:53 dtucker Exp $ */ +/* $OpenBSD: fmt_scaled.c,v 1.22 2022/03/11 09:04:59 dtucker Exp $ */ /* * Copyright (c) 2001, 2002, 2003 Ian F. Darwin. All rights reserved. @@ -185,8 +185,7 @@ scan_scaled(char *scaled, long long *result) /* truncate fpart so it does't overflow. * then scale fractional part. */ - while (fpart >= LLONG_MAX / scale_fact || - fpart <= LLONG_MIN / scale_fact) { + while (fpart >= LLONG_MAX / scale_fact) { fpart /= 10; fract_digits--; } |