Once you get away from regular desktop computers, even non-malicious software errors can cause spectacular hardware failures:
The Mars Climate Orbiter - over $500 million spent on misson, destroyed by a metric-to-imperial conversion error.
Ariane 5 Flight 501 - destroyed by an integer overflow bug, resulting loss of rocket and onboard spacecraft costing more than US$370 million.
Two $150million F-22 Raptor aircraft crashes - by different bugs.
Bugs in the FADEC software of the Chinook helicopter were at least partly to blame for the crash of ZD576 and death of 29 people.