From: rs <> Date: Fri, 11 Jul 2025 03:31:42 +0000 (-0500) Subject: Send bytes instead of string X-Git-Url: https://git.the-white-hart.net/?a=commitdiff_plain;ds=inline;p=gemini%2Fcbs-server.git Send bytes instead of string --- diff --git a/cbs-srv.py b/cbs-srv.py index be2bb15..2778b37 100755 --- a/cbs-srv.py +++ b/cbs-srv.py @@ -232,7 +232,7 @@ def main(): conn.sendall('{} {}\r\n'.format(x.code, x.meta).encode('utf-8')) except Exception as x: logging.error('Exception: {}'.format(x)) - conn.sendall('40 Server error\r\n') + conn.sendall('40 Server error\r\n'.encode('utf-8')) conn.shutdown() conn.sock_shutdown(socket.SHUT_RDWR)