flatulence hurting ?

Before my two month old farts he's really upset and soon it comes out he cry a bit then he feels better. What should I do ?