Preventing corrosion of liquid-swept surfaces