From 35e7e4de35abf0e905afee8613470536f4bd4036 Mon Sep 17 00:00:00 2001 From: Marek Marczykowski Date: Thu, 23 Jun 2011 17:04:02 +0200 Subject: [PATCH] Fix root account setup Set password only when provided. In Qubes root account is locked, so no password is provided by user... --- anaconda/users.py | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/anaconda/users.py b/anaconda/users.py index 1748dfd..117bf29 100644 --- a/anaconda/users.py +++ b/anaconda/users.py @@ -252,10 +252,11 @@ class Users: def setUserPassword(self, username, password, isCrypted, lock, algo=None): user = self.admin.lookupUserByName(username) - if isCrypted: - self.admin.setpassUser(user, password, True) - else: - self.admin.setpassUser(user, cryptPassword(password, algo=algo), True) + if password: + if isCrypted: + self.admin.setpassUser(user, password, True) + else: + self.admin.setpassUser(user, cryptPassword(password, algo=algo), True) if lock: self.admin.lockUser(user)