]> git.ipfire.org Git - thirdparty/systemd.git/blobdiff - src/core/socket.h
Merge pull request #31899 from yuwata/sd-journal-add-match
[thirdparty/systemd.git] / src / core / socket.h
index 6813bdcf8c8e1faed413937db02d638e5b01ae5d..973a697f86154ed10aec7a6b1562d9a536674cc0 100644 (file)
@@ -5,6 +5,7 @@ typedef struct Socket Socket;
 typedef struct SocketPeer SocketPeer;
 
 #include "mount.h"
+#include "pidref.h"
 #include "socket-util.h"
 #include "unit.h"
 
@@ -91,7 +92,7 @@ struct Socket {
         CGroupContext cgroup_context;
 
         ExecRuntime *exec_runtime;
-        DynamicCreds dynamic_creds;
+        CGroupRuntime *cgroup_runtime;
 
         /* For Accept=no sockets refers to the one service we'll
          * activate. For Accept=yes sockets is either NULL, or filled
@@ -104,7 +105,7 @@ struct Socket {
 
         ExecCommand* control_command;
         SocketExecCommand control_command_id;
-        pid_t control_pid;
+        PidRef control_pid;
 
         mode_t directory_mode;
         mode_t socket_mode;
@@ -159,6 +160,8 @@ struct Socket {
         char *fdname;
 
         RateLimit trigger_limit;
+        usec_t poll_limit_interval;
+        unsigned poll_limit_burst;
 };
 
 SocketPeer *socket_peer_ref(SocketPeer *p);
@@ -168,13 +171,18 @@ int socket_acquire_peer(Socket *s, int fd, SocketPeer **p);
 DEFINE_TRIVIAL_CLEANUP_FUNC(SocketPeer*, socket_peer_unref);
 
 /* Called from the service code when collecting fds */
-int socket_collect_fds(Socket *s, int **fds);
+int socket_collect_fds(Socket *s, int **ret);
 
 /* Called from the service code when a per-connection service ended */
 void socket_connection_unref(Socket *s);
 
+SocketPort *socket_port_free(SocketPort *p);
+DEFINE_TRIVIAL_CLEANUP_FUNC(SocketPort*, socket_port_free);
+
 void socket_free_ports(Socket *s);
 
+int socket_port_to_address(const SocketPort *s, char **ret);
+
 int socket_load_service_unit(Socket *s, int cfd, Unit **ret);
 
 char *socket_fdname(Socket *s);