"I can see how it protects the interests of a few people who wield power - the inner circle. But how does it keep North Korea safe?"
Messy transition processes in the middle of a crisis completely undermines the ability of a government to handle a crisis. What would be better, a smooth transition in which there is a sense of continuity with the past or continual internal intrigue and jockeying for position? Consider the fact that Kim Il Sung died in the middle of the worst natural disasters in DPRK history, with its entire food production annihilated by flood. Many a government has collapsed in the face of crisis due to undue emphasis on electioneering and government transitions. For example, I am studying Somalia quite a lot. The parliamentary government collapsed in 1969 after a messy election. It seemed the elites were only concerned with elections and various factions jockeying for position, and not concerned with Somalia's economic problems. The people of Somalia overwhelmingly supported the coup which followed.
Then there's the very real fact that bourgeois-style elections, in which counterrevolutionary parties are openly allowed to compete, almost always result in coup attempts and foreign meddling. Look at all the CIA-led Color Revolutions. Look at the coups waged against progressive leftwing governments the world over, especially in Latin America, also Indonesia in which between 500,000-1,000,000 members of the CPI were slaughtered by the US & Australian backed Suharto regime. You can't act as if "political liberalization" incurs no risks to the regime itself, a regime which the US & South Korea actively have sought to destroy for 60 years and in South Korea's case, they lock up anybody who is openly sympathetic with socialism. But nobody is saying they should become more democratic, are they? You yourself said it'd be good if the southern militarists would take over the north, and thereby implement their National Security Law over the whole country with nary a word of protest from the anti-communists.
To me, whenever people preach about democracy and human rights, it almost inevitably involves the locking up or killing leftists and the allowance of counterrevolutionary terrorism and insurrection.
The point is, conditions matter when you're lecturing others about their so-called lack of democracy. You can't constantly threaten a country and then except it to be a liberal democratic utopia. It's going to defend itself.