Ariane flight V88
The first Ariane 5 broke up 37 seconds after launch on 4 June 1996, taking the four Cluster science spacecraft with it. Inertial reference code reused from Ariane 4 converted a 64-bit floating-point value, the horizontal bias, into a 16-bit signed integer. Ariane 5's faster trajectory produced a number too large to fit, the unhandled exception halted both inertial reference units, and the rocket steered itself to destruction.
The cruel detail is that this alignment function served no purpose after lift-off. Redundancy did not help because both units ran identical software. The inquiry's recommendations, on handling exceptions and testing reused code against the new vehicle's real trajectory data, are still taught today.
More about Ariane flight V88