]> git.ipfire.org Git - thirdparty/systemd.git/commit
core/socket: introduce intermediate SOCKET_START_OPEN state
authorMike Yuan <me@yhndnzj.com>
Mon, 16 Dec 2024 00:54:11 +0000 (01:54 +0100)
committerMike Yuan <me@yhndnzj.com>
Mon, 30 Dec 2024 23:22:52 +0000 (00:22 +0100)
commit58a86a15047389909bc9c50b9940883dd231d56a
tree69dbe0841af4c08b163596c7d3d0d7552f8d6f4f
parent80706c32699882ac12b5a0953bc6b500e924a1a3
core/socket: introduce intermediate SOCKET_START_OPEN state

Prior to this commit, if no Exec*= is defined for socket,
and the unit was in SOCKET_FAILED state, failure of socket_open_fds()
would induce state transition SOCKET_FAILED -> SOCKET_FAILED,
and OnFailure= deps get unexpectedly skipped. Let's introduce
an intermediate state, so that during unit start we enter
UNIT_ACTIVATING at least once.

Fixes #35635
src/basic/unit-def.c
src/basic/unit-def.h
src/core/socket.c