The risk of a region-wide war is increasing, but if cooler heads prevail, a peaceful arrangement can still be reached.