The military, preoccupied by a war against militants and reluctant to assume direct responsibility for the economic crisis, has made clear it is not eager to take over the government, as it has many times before, military officials and politicians said.

But the government’s performance since the floods, which have left 20 million people homeless and the nation dependent on handouts from skeptical foreign donors, has laid bare the deep underlying tensions between military and civilian leaders.

American officials, too, say it has left them increasingly disillusioned with Mr. Zardari, a deeply unpopular president who was elected two and a half years ago on a wave of sympathy after the assassination of his wife, former Prime Minister Benazir Bhutto…

Having secured an exceptional three-year extension in his post from Mr. Zardari in July, General Kayani appears determined to prevent the economy from bankruptcy. Military officers in the main cities have been talking openly and expansively about their contempt for the Zardari government and what they term the economic calamity, an unusual candor, reporters and politicians said.