My guess is that the only out they'd have with this is if the purchase contract specified that any legal liability might remain with the previous owners but it's unusual to find anyone who will agree to that with a sale.
The possibilities are that they did not perform proper due diligence on the code that they bought, which should have brought this to light (and a giant the size of google really should know how to do a code audit) (bad), the second possibility is that they did do proper due diligence, were aware of the provenance of this chunk of code and chose to ignore it (bad), the third is that the code got incorporated after the sale (bad).
There are no 'goods' here, the central question is if this is a part that is critical.
That said, I'm fairly sure that any large enough software project that has had contributions from large numbers of sources is subject to this kind of pollution, unless very strict measures are taken to avoid it.