to bail out

The action of "rescuing" someone or something from a bad situation. See bailout.