Bring in the vendor's fix for a bug in strtod() whereby

strtod("0xyz", &endp) resulted in endp pointing to "0xyz"
instead of "xyz".

Reported by:	Tony Finch <dot@dotat.at>
MFC after:	1 week
This commit is contained in:
David Schultz 2008-06-21 19:27:54 +00:00
parent 0ee1368a96
commit c713eaa603
Notes: svn2git 2020-12-20 02:59:44 +00:00
svn path=/head/; revision=179918

View File

@ -113,8 +113,11 @@ gethex( CONST char **sp, FPI *fpi, Long *exp, Bigint **bp, int sign)
e += e1;
}
*sp = (char*)s;
if (zret)
return havedig ? STRTOG_Zero : STRTOG_NoNumber;
if (zret) {
if (!havedig)
*sp = s0 - 1;
return STRTOG_Zero;
}
n = s1 - s0 - 1;
for(k = 0; n > 7; n >>= 1)
k++;