From 529f768ab85917b5404754334ed0212076e562eb Mon Sep 17 00:00:00 2001 From: Lennart Poettering Date: Wed, 27 Sep 2023 17:21:51 +0200 Subject: [PATCH] socket: drop redundant TAKE_FD(cfd) line In the only two codepaths we reach this place we know that cfd is already invalidated. In the Accept=yes case there's already a TAKE_FD() a few lines further up, and in the Accept=no case there is no connection fd anyway. --- src/core/socket.c | 1 - 1 file changed, 1 deletion(-) diff --git a/src/core/socket.c b/src/core/socket.c index 43f412bc895..0b5bfd26487 100644 --- a/src/core/socket.c +++ b/src/core/socket.c @@ -2432,7 +2432,6 @@ static void socket_enter_running(Socket *s, int cfd_in) { unit_add_to_dbus_queue(UNIT(s)); } - TAKE_FD(cfd); return; refuse: