The line of reasoning illustrates the sunk-cost fallacy.
Basically, the money and lives in the war were already invested. The idea behind it is that if you leave the war then it will all be in vain. Since it was already invested, then there's no reason to leave the war since the costs have to be returned and his idea would be that by staying in the war you might win and then have the benefits that outdo the costs.