Sometimes I've gotten the advice to drip a few drops of valve oil in my trumpet's leadpipe before putting on the mouthpiece and start playing. Allegedly this would help to prevent tarnishing and buildup inside of the pipes. Now does this make sense or is it a myth?
It's usually favored by some to help cut down on issues with red rot. A better approach for that is probably a leadpipe swab, like the one Tim Wendt (well known NYC pit musician) makes and sells for trumpet players.
Reynold Schilke supposedly recommended oiling valves through the leadpipe, rather than removing the valve caps, as "the way" to oil valves for years, but I think that was mainly for students, when he worried they might accidentally damage the valves by removing them from the valve block carelessly.
A few drops of valve oil certainly won't hurt with buildup in the leadpipe, but it's not clear that it definitely helps either. Your best bet is to wash it regularly and don't leave moisture in it when you finish playing for the day, especially if you're going to put it in a case and leave it stored for a long period of time.
The expression "red rot" is used among brass musicians and repair techs to cover two distinct conditions, surface corrosion, and alternately, deterioration of the alloy (most commonly in the leadpipe) due to zinc leaching out of the brass.
It can usually be spotted early, by round 'pink' circles discoloring the brass (assuming the instrument is not silver plated or has some other coating to hide the condition). It takes many, many years to go far enough to create small pinholes in the brass tubing, but it is something you want to avoid. The use of a leadpipe swab mentioned above is usually the most often recommended to avoid it happening.
It also appears that diet of the instrument's owner may be related, particularly the amount of acid in their saliva may accelerate the process. It's helpful to not eat food or drinks other than plain water right before playing and to brush your teeth when possible to avoid, for example, food particles and soft drinks being blown into the instrument after a meal or snack.
Good question - it is a silly myth.
If you really want to prevent tarnishing and buildup, brush your teeth before you play / keep your mouth clean. Clean your trumpet regularly (and I mean, a FULL bath clean!) Have it serviced by a certified tech regularly, and always stay on top of your maintenance with oil, slide grease, etc.
Too much oil in the instrument can actually add to an increase of buildup, so you shouldn't use more oil than necessary.