I use to get this thoughts as well . What help me a lot is to just let the thoughts go by don't try to take control let it do its thing and those thoughts will go away simple as that. the more times you try to control it the more bad the thoughts will be . Good luck
The thing is, I am actually not worried at all when I start casting the spell. It is all good, until bad thoughts spring up from nowhere. And sometimes it isn't just thoughts, but also intentions. I'll give another example: sometimes at night I feel afraid, and as my mind wanders to what demons might be lurking in the night, I might start involuntarily drawing energy in order to summon them. I hope that made sense. That is why I personally think it's a psychic attack.
Although your claim has some short of basis by saying that healing and protection should only be applied when the harmful factor are removed, are you aware that sometimes you can hamper the cause of the problem through interrupting it? For example, if I am let's say, haunted, and someone casts a protection spell over me that is very strong, the spirit that haunts me will get energitically disconnected from me. This if course means that the malevolent spirit, devoid of its energy supply, might at the start try to stir up a lot of trouble as a last resort or strike directly on the protective barrier the spell provides. But if the spell is indeed strong and well layered, the spirit will lose the fight and will be forced to buzz off.
I am not playing smart here. I just want to tell you that magick can be flexible.
It is not my intention to undervalue things, but we should use rites or spells of different intensity according to the situation. Again, for example, you shouldn't try to exorcise an ancient demon by simply drawing a hexagram, but you shouldn't go to such great lenghths by trying to banish a playful fairy the way you would banish a greater demon of some short.
Something regarding the curse or haunting thing, by my personal observations, there is a probability that I am both cursed and targeted. I just hope that I am not cursed to be haunted by a spirit, because this would mean that a spirit is attached to me not just through a simple energy bond, but by another, more advanced one along with it. And depending on how well done the curse was, the more troublesome it will be trying to get rid of a haunting of this nature.