uck - comparing string representations of real numbers is really not a good way to test for correctness !  Equality comparisons of reals are generally a bad plan.
However, I see you're only using six digits after the decimal point (let me guess, %f is used); and even 32-bit processors are precise enough that we shouldn't see rounding glitches - and I can't think of a better test, sadly.