The first bug everyone talked about was the ddos bug. Miners could write some funny transactions where one input is used multiple times.
Of course such a transaction is not valid and should be rejected by the nodes. But due to a bug in the code that transaction would simply crash the node. In that way large parts of the network could be switched offline.
While this bug is certainly annoying, the real problem was introduced one version of bitcoin core later. Now the nodes would no longer crash on these transactions, but incorrectly accept them as valid transaction. That would allow miners to double spend bitcoin, creating extra bitcoin on the fly. No more 21 million fixed bitcoins.
The bitcoin core team choose to put the focus on the former bug and then fix both bugs. Because there is no reason why a miner would actively want to trigger a network outage, while they might want to get some extra coins.
This worked well and no such transaction was propagated. Now the bug is fixed and going back would cause a hard fork.
We were actually came really close to some serious troubles for bitcoin. But it also shows that even in the most secure cryptocurrency there are flaws and further problems are to be expected. Lets hope they get solved as nicely as this fatal bug.