I was discussing the bug I found with a couple friends, and as we were analyzing the logic of it, my thoughts were along the lines of hidden units shouldn't be beholden to open border rules; ie, they should behave like Loki when he's attacked. That could solve the game crashing nature of the bug (which neccesitates a alt-ctrl-del Windows signout if not a hard system restart on Fullscreen Mode for me as the game won't release and minimize the overlay to address the Dump File window - solved by switching Civ IV to Windowed Mode): Using my screenshot as an example, we know that if a fireball or other unit fails to kill a Hidden Ghost or Shadow, and that Ghost or Shadow Withdraws or is otherwise forced to move by the nature of an enemy unit sharing the tile, they cannot move to a tile occupied by an enemy unit; they cannot move to a Mountain or Coast/Ocean Tile [as it's unlikely they'll have promotions or skills allowing it]: Here, the only other tiles available would be 'closed' 3rd Party rival territory (no Open Borders). But, as Stealthed Units, this shouldn't matter as the 3rd Party rival Civ wouldn't 'know' they're there.
Extreme case (ie, trying to corner and kill Loki situations): The Stealthed Units Withdraw or are otherwise forced to retreat, and all eight tiles are occupied by the Hostile Actor (Player or AI at war with them) or Impassible Terrain. In such situations, to prevent a game crash, override combat results and force a defeat for the defender and a victory for the attacker? A: Is that even possible? B: Does that infringe on Balance Issues? C: Situation not yet coming to mind?
Obviously, this is a fairly esoteric bug to begin with and the more I think of it and how it works the more I'm amused by it (outside of the Fullscreen Mode issue).