I don't agree with this.
What you describe is rumination. Rumination has been demonstrated to be beneficial in resolving problems. Depressed people ruminate a lot, and I remember seeing at least one article (don't ask for a reference - I don't remember where) that claimed that this was because rumination worked as a tool to get us to focus on resolving a problem.
Rumination is an indication of focus, not of a wandering mind, even though it might superficially seem like wandering because we turn to rumination all the time whenever we have "spare cycles" and there is something important on our mind.
Meditation might also affect rumination in that it changes your mindset and a lot of the things that you previously thought was massively important and worth ruminating about start turning into inconsequential non-events to you, but that's entirely separate from reducing "wandering", and meditation won't stop you from ruminating on things you really care about (though it might train you to be more focused on when you do it and not let it cut into your relaxation, for example).
But what I at least think of as the mind wandering is the type of random chatter that leads you to go check Hackernews one second because it popped into your head that you hadn't checked it for five minutes, and leads you to grab a snack the next because you suddenly felt an urge for sugar, and have you sit and blankly dream about that vacation you'd wanted to book a few minutes later.