This truly classic formula for computing the area of a triangle is numerically unstable for needle-like triangles (triangles where one side is considerably shorter than both of the other two sides). This is particularly true if single precision floating point arithmetic is used to compute the formula.
A more numerically stable approach is to sort the lengths of the three sides such that a >= b >= c and then compute the area of the triangle using:
sqrt( ( a + ( b + c ) ) * ( c - ( a - b ) ) * ( c + ( a - b ) ) * ( a + ( b - c ) ) ) / 4
remove any parentheses from this formula!
Note that if c - ( a - b ) is less than zero then the above formula will yield a NaN. This indicates that the values a, b and c are not side-lengths of a valid triangle.
For more information, see Floating-Point Computation by P. Sterbenz (1973) Prentice-Hall.