Skip to content

Commit

Permalink
avoid error is password file cannot be read
Browse files Browse the repository at this point in the history
git-svn-id: https://xpra.org/svn/Xpra/trunk@4608 3bb7dfac-3a0b-4e04-842a-767bc560f471
  • Loading branch information
totaam committed Oct 23, 2013
1 parent 0b237da commit a71032d
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions src/xpra/client/client_base.py
Original file line number Diff line number Diff line change
Expand Up @@ -399,6 +399,8 @@ def get_encryption_key(self):
def load_password(self):
filename = os.path.expanduser(self.password_file)
password = load_binary_file(filename)
if password is None:
return None
password = password.strip("\n\r")
log("password read from file %s is %s", self.password_file, "".join(["*" for _ in password]))
return password
Expand Down

0 comments on commit a71032d

Please sign in to comment.