Fix error message encoding
- Use the correct unicode string for an error message, otherwise an exception will generate another exception about incorrect type, masking the original error. Signed-off-by: Simo Sorce <simo@redhat.com> Reviewed-By: Alexander Bokovoy <abokovoy@redhat.com>
This commit is contained in:
1 parent
cc5ad6b3f9
commit
2f567f0e8e
1 file changed
+2
-1
+2
-1
@@ -603,7 +603,8 @@ class KerbTransport(SSLTransport):
|
||||
except (TypeError, UnicodeError):
|
||||
pass
|
||||
if not token:
|
||||
raise KerberosError(message="No valid Negotiate header in server response")
|
||||
raise KerberosError(
|
||||
message=u"No valid Negotiate header in server response")
|
||||
token = self._sec_context.step(token=token)
|
||||
if self._sec_context.complete:
|
||||
self._sec_context = None
|
||||
|
||||
Reference in new issue
Block a user