This is one of Machiavelli's 27 Rules of Military Discipline, which he set down as his advice to generals. This rule is an example of the argument that war is a zero sum game; that is, that both sides in war are competing for a limited 'pool' of resources and that anything that strengthens one side must necessarily weaken the other and vice versa. A similar argument can be found in Clausewitz.
While it seems to be one of the most self-evident statements that could possibly be made about war, it is actually of debatable truth and may be counterproductive when applied to actual warfare. The ultimate expression of the doctrine of warfare as zero sum game can be found in the total warfare waged during the twentieth century, especially during the Second World War. In this war, all the major combatants engaged in mass-scale attacks against civilians, especially in the form of aerial terror bombing of refugee columns and cities.
Examining the situation from the perspective of RAF Bomber Command, one of the major perpetrators of attacks against civilians during the war, we see clear signs of a zero-sum game mentality. To men like Sir Arthur Harris, it was obvious that bombing enemy cities would harm the enemy; it was equally obvious that not being bombed would benefit the enemy. Therefore, applying the tenet above, Bomber Command resolved to bomb German cities with the goal of breaking the German people's collective will to fight.
After the war, the usefulness of this devastating bomber campaign was called into question. British night bombing attacks were wildly inaccurate, and the overwhelming majority of bombs fell far from their nominal targets. The bombing campaign certainly destroyed a lot of homes and property, but for most of the war, most of this property was in the form of houses and shops not critical to the German war effort
Many historians have concluded that Bomber Command's night bombing campaign was both a waste of resources and an atrocious act, in light of the indiscriminate manner in which its attacks fell on civilians.
In and of itself, this would not present a logical flaw in the image of war as a zero-sum game; it is quite possible that some strategies in a zero-sum game will result in a lot of cost for little benefit, or that some beneficial strategy will involve atrocities against a civilian population. However, it must be kept in mind that the men who ordered and organized the bomber campaign were thinking in Machiavellian/Clausewitzian terms. They were simply applying the dictum that "what benefits you, harms the enemy."
A similar disastrous result can be seen in the stalemated trench warfare of 1914-17 during World War One. At this time, all the major European powers were avid followers of Clausewitz. As a result, all the European powers ended up with essentially similar grand strategies reliant on grinding their enemies down in a battle of attrition. This attempt at attrition was fueled by the belief (drawn from what is perhaps a mistaken version of Clausewitz) that every shell fired at the enemy, every man sent against his lines, brought the enemy's defeat one step closer. In reality, it was the attackers who were driven back step by step, and the defenders were the ones winning the battle of attrition by suffering proportionately fewer losses than their enemies. This is one of the reasons the war dragged out into and through 1917.
Ultimately, both sides 'lost' World War One. The Central Powers lost all semblance of stable government; Austria-Hungary disintegrated all at once and Germany rapidly found itself in a downward spiral of political chaos that would not truly fade until the rise of the Nazis. Meanwhile, the Russian elite were mostly massacred by the Bolsheviks, and the lost generation of French and British Great War veterans were left depressed and pacifistic. Even the victors ultimately lost their colonial empires for reasons that found many of their origins in the aftermath of the Great War.
Similarly, it is not clear that either side 'won' the night bombing attacks. The British spent many millions of pounds building up Bomber Command, which suffered heavy casualties during the attack. Meanwhile, the Germans had to repair destroyed buildings that, while valuable, were not essential to the war effort. Ultimately, the bombing campaign left the heart of Europe devastated, making it difficult for friendly troops to move forward and making postwar recovery very difficult.
This problem of cases where both sides lose a war is even more apparent in the age of nuclear weapons. Today, any missile-armed party could probably attack another missile armed party, inflict horrendous losses against the enemy, and still lose the war
This leads to the conclusion that war is not inevitably a zero-sum game; in some wars it may be foolish to do a certain thing, even though it would hurt your enemy.