Tips on Loose Joints?

Hi everyone! A good friend of mine gave me this amazing TFA Battle Damaged Optimus Prime figure and I’m curious about how to fix the loose joints? I wanna put him with the rest of my Prime figures. Thank you!