Even though I told you that welding weakens the metal, not to mention an already weak rusted metal frame, it is still possible to salvage it from the rust through welding. You must follow a lengthy but straightforward procedure to accomplish that.
First, clean the metal surface with a wire brush of steel. When cleaning, wash the frame with detergent water to clear away all rust particles. Now, you can move on to weld the frame as usual.