Yes, any device can be damaged by the acid from a leaking battery, but batteries dont' just open the spigot as soon as they die.
In fact, it usually takes quite a while for a dead battery to bleed out, so a dead battery isn't the problem; time is.
If you typically use your batteries all the way to dead like I do, the key is to USE them all the way to dead and then change them out.
It's leaving a low-charge or dead battery in a light for months that's going to bite you in the end.
The only (ONLY, only, only) times I've ever opened up a device (flashlight or otherwise) and found an acid mess from a leaking battery is when I had left the device untouched and forgotten somewhere for (typically) more than a year.
So, use 'em up, and when they're dead, change 'em out.
Then one more leg of that strategy is to do what I do with "emergency" lights that I keep in a trunk or back of a closet; besides making sure that those batteries are way out date wise (5 years or more), what I do is keep the batteries in a sealed plastic storage container on top of which sits my empty flashlight and to which I've strapped the battery container and flashlight together with a couple wraps of electrical tape so they don't get separated.
That way, if I forget those lights for too long, the batteries only bleed out into a plastic sealed container, but if they're good when I need them, it only takes a few seconds to pop them into the light.
The other part of that same strategy is that I change out ALL my emergency batteries once each year, usually at Christmas because that's an easy to remember memory date. Then I use up the rotated-out batteries in things I use all the time.
This all sounds complicated, but it's not.