How to cure music influence on mind?
These songs in the mind are hindances. To stop them, yes, stopping listening to songs.

And what is the nutriment for the five hindrances? It should be said: the three kinds of misconduct. The three kinds of misconduct, too, I
say, have a nutriment; they are not without nutriment. And what is the
nutriment for the three kinds of misconduct? It should be said:
non-restraint of the sense faculties. Non-restraint of the sense
faculties, too, I say, has a nutriment; it is not without nutriment.
And what is the nutriment for non-restraint of the sense faculties? It
should be said: lack of mindfulness and clear comprehension. Lack of
mindfulness and clear comprehension, too, I say, has a nutriment; it
is not without nutriment. And what is the nutriment for lack of
mindfulness and clear comprehension? It should be said: careless
attention. Careless attention, too, I say, has a nutriment; it is not
without nutriment. And what is the nutriment for careless attention?
It should be said: lack of faith. Lack of faith, too, I say, has a
nutriment; it is not without nutriment.
AN 10.61