summaryrefslogtreecommitdiff
path: root/missing/dtoa.c
diff options
context:
space:
mode:
Diffstat (limited to 'missing/dtoa.c')
-rw-r--r--missing/dtoa.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/missing/dtoa.c b/missing/dtoa.c
index a940eabd91..b7a8302875 100644
--- a/missing/dtoa.c
+++ b/missing/dtoa.c
@@ -1552,6 +1552,7 @@ break2:
if (!*++s || !(s1 = strchr(hexdigit, *s))) goto ret0;
if (*s == '0') {
while (*++s == '0');
+ if (!*s) goto ret;
s1 = strchr(hexdigit, *s);
}
if (s1 != NULL) {
@@ -1574,7 +1575,7 @@ break2:
for (; *s && (s1 = strchr(hexdigit, *s)); ++s) {
adj += aadj * ((s1 - hexdigit) & 15);
if ((aadj /= 16) == 0.0) {
- while (strchr(hexdigit, *++s));
+ while (*++s && strchr(hexdigit, *s));
break;
}
}