From: Dustin Martin Date: Tue, 23 Aug 2022 14:00:46 +0000 (-0700) Subject: protocol: ignore resize message if process freed (#968) X-Git-Url: http://git.prime8.dev/?a=commitdiff_plain;h=69b63fcfd7490c2bf48eb6332028f98848be74ac;p=ttyd.git protocol: ignore resize message if process freed (#968) --- diff --git a/src/protocol.c b/src/protocol.c index 5341c3d..cc0945b 100644 --- a/src/protocol.c +++ b/src/protocol.c @@ -314,6 +314,7 @@ int callback_tty(struct lws *wsi, enum lws_callback_reasons reason, void *user, } break; case RESIZE_TERMINAL: + if (pss->process == NULL) break; json_object_put( parse_window_size(pss->buffer + 1, pss->len - 1, &pss->process->columns, &pss->process->rows)); pty_resize(pss->process);