It is just about impossible to stop corrosion on magnesium once it gets started. Paint won't work. The corrosion is intergrannular and a surface coating will simply allow the corrosion to continue underneath.
The best bet is a thick oil that can penetrate and remain there. Products like LPS-3, Cosmoline, Par-Al-Ketone, Boeshield, Corrosion X heavy duty, and so on are often very thick oils, thinned with a carrier (like lacquer thinner, MEK, acetone or similar) .
The oils penetrate and then become waxy. They do a great job of corrosion prevention. However, they must be applied regularly for effective protection.
My guess is that you are not seeing corrosion anywhere the chain oil is. Just where it's dry.