fix (and test) for bug #43722

git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/base/trunk@38213 72102866-910b-0410-8b05-ffd578937521
This commit is contained in:
Richard Frith-MacDonald 2014-11-29 11:02:23 +00:00
parent e6ed085192
commit ca81536515
3 changed files with 29 additions and 9 deletions

View file

@ -1243,6 +1243,7 @@ GSScanDouble(unichar *buf, unsigned length, double *result)
int exponent = 0;
BOOL negativeMantissa = NO;
BOOL negativeExponent = NO;
BOOL extra = NO;
unsigned pos = 0;
int mantissaLength;
int dotPos = -1;
@ -1301,14 +1302,8 @@ GSScanDouble(unichar *buf, unsigned length, double *result)
{
/* Mantissa too long ... ignore excess.
*/
if (19 == mantissaLength && (dotPos < 0 || dotPos >= mantissaLength))
{
mantissaLength--;
}
else
{
mantissaLength = 19;
}
mantissaLength = 18;
extra = YES;
}
if (dotPos < 0)
{