By Syed Shoaib Hasan
BBC News, Islamabad
Pakistan's Supreme Court has issued a key ruling on electoral registers a day after President Pervez Musharraf backed away from implementing emergency rule.
Musharraf faces a battle to remain army chief and president
The court ordered officials to produce a completed list of voters within 30 days after hearing a petition from former PM Benazir Bhutto.
Ms Bhutto alleges there are 30 million "missing" voters.
The decision comes a day after Gen Musharraf stepped back from measures that would have cut judicial powers.
The court is headed by Chief Justice Iftikhar Chaudhry, who was suspended by President Musharraf on abuse of power charges in March but later reinstated following a lengthy and vocal opposition campaign.
'Committed to democracy'
Chief Justice Chaudhry said during the hearing held in Islamabad on Friday: "The success of democracy in Pakistan depends on the voters' list."
Ms Bhutto's lawyer, Latif Khosa, had argued that 30 million people had not been added to the 2002 electoral list.
"Even the 2002 list is short of 20 million voters according to the records of the national data base authority," he said. "This has now increased by 10 million."
During the hearing the government pleaded to be allowed 140 days to complete the list.
This would have meant the list would be presented on or after the election date, due in November.
Mr Khosa strongly resisted this demand, saying: "The government is conspiring to deprive voters of their constitutional rights."
The court ruled the government must produce the list in 30 days.
On Thursday a Pakistani government spokesman said there had been pressure on Gen Musharraf to declare an emergency but that he had decided not to because he was "committed to democracy".
US President George W Bush said on Thursday he wanted free and fair elections in Pakistan.
Emergency rule would have limited the role of the courts, restricted civil liberties and curbed freedom of expression.
Chief Justice Chaudhry has had a long run-in with Gen Musharraf
The president would have also been able to postpone national elections, which could have enabled him to continue in his role as chief of Pakistan's powerful military.
Opposition political parties, like Pakistan's largest party, the PPP, want Gen Musharraf to give up the army role.
Friday's court order was the second in as many days relating to the national elections.
On Thursday, the Supreme Court issued notices to the federal and provincial governments over a petition by another former PM.
Nawaz Sharif, who was deposed by Gen Musharraf in a coup, said he and his brother were being prevented from returning to Pakistan despite a 2004 Supreme Court order allowing them to come back.
Nawaz Sharif, his brother and Ms Bhutto are all in exile abroad.
The court demanded to know who had prevented the Sharifs' return.
"I think this is a major victory... it vindicates our stand," said Ahsan Iqbal, a senior leader of Mr Sharif's PML-N party. "The government is afraid of us.
"Emergency rule and martial law are no longer an option," said Mr Iqbal.
"The media, judiciary and civil society are now so strong that no-one can think about it."