https://issues.apache.org/bugzilla/show_bug.cgi?id=43940

--- Comment #39 from Glenn Adams <[email protected]> ---
(In reply to comment #38)
> (In reply to comment #36)
> > The bug is trivial:
> > "if (source >= 10e-3 && source < 1e7) {" is wrong !
> > "if (source >= 1e-3 && source < 1e7) {" is right.
> > 
> > My mistake when reading 10 exp -3 in Double.toString javadoc and writing
> > 10e-3 instead of 1e-3.
> > 
> > Patch will follow.
> 
> i'm not satisfied with this patch, since it depends upon the implementation
> specific nature of Double.toString(); i would like to see better checking in
> the code I listed in comment 34 to remove assumptions about the use of
> scientific notation (and assuming that 'E' is present)

for example, what happens if source is NaN? just looking at the code makes me
think the same else clause cited in comment 34 will apply, which means yet
again, that parseInt will be invoked on the string "NaN"

-- 
You are receiving this mail because:
You are the assignee for the bug.

Reply via email to