If we were to follow the principle of not speaking ill of the dead in the case of Musharraf, then we would also have to defend neo-Nazis who praise Adolf Hitler. The Surah Abu Lahab in the Quran would also not exist. Musharraf was a war criminal and is responsible for many of the current issues in Pakistan. It is important to do what is necessary and speak the truth, regardless of the circumstances.
Musharraf was responsible for the deaths of 70,000 people, yet some still try to justify his actions. They defend his decisions such as leaving soldiers stranded in Kargil, imposing martial law on Oct 12th, 1999, the conflict in Dera Bugti, and the Lal Masjid operation. It’s important to speak out against such injustices, as failing to do so will allow his sympathizers to control the narrative.