From fee2e42be60a37d4172ebd17751111ec760190c5 Mon Sep 17 00:00:00 2001 From: Simon Tatham Date: Fri, 13 Mar 2020 22:48:15 +0000 Subject: [PATCH] uxser: add a missing uxsel_del. If we close a serial port fd, we shouldn't leave it active in uxsel. That never ends well. (cherry picked from commit 6b77fc627a7b428e5d4854bb1092fb23f25e9ddc) --- unix/uxser.c | 1 + 1 file changed, 1 insertion(+) diff --git a/unix/uxser.c b/unix/uxser.c index f38a8eac..f3aaec6c 100644 --- a/unix/uxser.c +++ b/unix/uxser.c @@ -333,6 +333,7 @@ static const char *serial_init(Seat *seat, Backend **backend_handle, static void serial_close(Serial *serial) { if (serial->fd >= 0) { + uxsel_del(serial->fd); close(serial->fd); serial->fd = -1; }