Your troops return into your Catacombs without attacking of a hostile Strognhold or Stash in the following cases:
1. Your opponent has activated Total Protection over his Stronghold.
2. Your opponent has relocated his Stronghold to another place on the global map.
3. The targeted Stash had depleted before your battle squad has arrived to capture it.
4. Your units will return to the Stronghold without attacking a Stash if your opponent loses his control over it. Please note that it is impossible to attack a Stash Island which isn't controlled by any player.
Many players use such a tactic to minimize their losses: when the player who keeps some Stash notices that this Stash was attacked several times, he recalls his reinforcements remaining it vacant.