From 4b57cb785e53955900cb7bced68f77af410b56ff Mon Sep 17 00:00:00 2001
From: Stanislav Laznicka <slaznick@redhat.com>
Date: Tue, 19 Sep 2017 14:00:43 +0200
Subject: [PATCH] rpc: don't decode cookie_string if it's None

This removes an ugly debug message from client installation
---
 ipalib/rpc.py | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/ipalib/rpc.py b/ipalib/rpc.py
index 4b81e89975..0c2f981765 100644
--- a/ipalib/rpc.py
+++ b/ipalib/rpc.py
@@ -901,6 +901,8 @@ def get_session_cookie_from_persistent_storage(self, principal):
         # (possibly with more than one cookie).
         try:
             cookie_string = read_persistent_client_session_data(principal)
+            if cookie_string is None:
+                return
             cookie_string = cookie_string.decode('utf-8')
         except Exception as e:
             logger.debug('Error reading client session data: %s', e)
