summaryrefslogtreecommitdiffstats
path: root/Objects/stringobject.c
diff options
context:
space:
mode:
Diffstat (limited to 'Objects/stringobject.c')
-rw-r--r--Objects/stringobject.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/Objects/stringobject.c b/Objects/stringobject.c
index 7f30f66..84e107b 100644
--- a/Objects/stringobject.c
+++ b/Objects/stringobject.c
@@ -4336,7 +4336,7 @@ formatfloat(char *buf, size_t buflen, int flags,
}
if (prec < 0)
prec = 6;
- if (type == 'f' && fabs(x)/1e25 >= 1e25)
+ if (type == 'f' && fabs(x) >= 1e50)
type = 'g';
/* Worst case length calc to ensure no buffer overrun: