At least in my country, legally speaking there is a case that you should send one of Y's trucks to X, as there is a risk of life.
Various towns requisition each others trucks, operators, and more during the bushfire season. And that requisition may just be a phone call with someone yelling that they need more help at the other end. And that's legally enforceable.
Maybe in the little thought experiment you're trying to conduct it does, but not in the real world. There are plenty of other variables at play.
X knows that if they need trucks and Ys are in use, then people die and they'll get blamed. They know that local trucks will respond faster so fewer people die.
In one off emergency situations in the real world, people actually help each other. We're not just a bunch of ideal game theory pieces in some amaeteur economist thought experiment.
I have a contract to rent you X fire trucks. I have other contracts with other people to rent Y fire trucks to them. There's a fire and X fire trucks are being used to save people in X+1 fires. That last person dies because you didn't rent X+1 fire trucks. I could have given you an additional fire truck in the allotment of Y. Morally you can make the case that I ought to give you one more fire truck but how have you made the case that legally I should give you a non contracted fire truck?
Destroying the truck renter's property rights by the state forcing me to give you my property (that +1 fire truck) but in the long run it results in under allocation of goods and theft-premium being added as a cost.