Gen. Abdul Razeq, one of Afghanistan's most powerful security commanders, was killed on Thursday in a shooting attack by a bodyguard that dealt a severe blow to the Afghan government ahead of parliamentary elections on Saturday, officials said.

Gen. Scott Miller, the top U.S. commander in Afghanistan who had been at a meeting with Razeq and the governor of the southern province of Kandahar only moments earlier, was not injured in the attack.

But Razeq, the Kandahar police commander, and the local head of the NDS intelligence service were both fatally wounded before the attacker was himself killed. Kandahar Gov. Zalmay Wesa was severely wounded and contradictory reports about whether he had survived could not immediately be resolved.