Filling gaps with a paintable acrylic-latex caulk cuts down on drafts and makes your trim look better than new. The secret to using caulk is to cut the tip smaller than you think it should be; too much caulk makes a mess. Also, instead of using a nail to break the inner seal, use a small wire so you don’t stretch out the nozzle. Also consider buying a dripless caulk gun, which will automatically back off the pressure after each pull on the trigger to prevent unwanted oozing.