China would not go to war over Pakistan. They have their own Muslim problems.
Though it might be a good diversion. Hmmmmmm.
Actually Pakistan has been very,very helpful in helping China dealing with it's Slammies in Xingjiang province-hence we don't hear about their problem in the same way as we hear about say,Russia.Or even the US.China has mobilised it's divisions on the Tibetan border with India everytime the India & Pakistan have been at threat of war or at war.