I think I see what your getting at, but I don't see why. Oh well.
I suppose the only way to detect if they unallied would be to run a trigger for if foes command at exactly one wraith of if allies command 0 wraith. (If there is only one wraith out there.) You don't want it constantly allying the wraith to the devourer owner. Because that gives you weird things like when you attack the allies, your unit simply twitches into an attacking position but doesn't attack.
Simply go if foes command any unit, set all players to ally or something.

[right][snapback]410493[/snapback][/right]
I'm not sure I get what you are suggesting. You seem to understand my problem, so I'll try to explain it a bit more to clarify:
I'm making a special forces map, where you get money when you kill stuff, but only when you manually attack said allied enemy. You can use the unally (auto target) and everything, but since that requires little aiming skill, I don't want the player to get money for such a kill.
So I don't want the ally to reset every 84 milliseconds. I know I can put a wait in there to wait something like 10 seconds before re-applying the ally, but Snipers Bald Locks seems to have developed a way to do this perfectly.