s3:smbd: add echo handler information to struct smbd_server_connection
authorStefan Metzmacher <metze@samba.org>
Mon, 22 Mar 2010 07:42:13 +0000 (08:42 +0100)
committerStefan Metzmacher <metze@samba.org>
Mon, 22 Mar 2010 16:15:12 +0000 (17:15 +0100)
metze

source3/smbd/globals.c
source3/smbd/globals.h

index a632aa2e9b5872b59d3577b3837cad8be7d60444..0284171baed847f75cef5f9437a50534cebd5bca 100644 (file)
@@ -151,4 +151,7 @@ void smbd_init_globals(void)
        if (!smbd_server_conn) {
                exit_server("failed to create smbd_server_connection");
        }
+
+       smbd_server_conn->smb1.echo_handler.trusted_fd = -1;
+       smbd_server_conn->smb1.echo_handler.socket_lock_fd = -1;
 }
index 9bccbadb43d27d9588fb4ea2ea0ee8621f12a2a9..6e5262a9917bc7585dff9a79dab94d99c886a092 100644 (file)
@@ -435,6 +435,25 @@ struct smbd_server_connection {
        bool allow_smb2;
        struct {
                struct fd_event *fde;
+
+               struct {
+                       /*
+                        * fd for the fcntl lock mutexing access to smbd_server_fd
+                        */
+                       int socket_lock_fd;
+
+                       /*
+                        * fd for the trusted pipe from
+                        * echo handler child
+                        */
+                       int trusted_fd;
+
+                       /*
+                        * fde for the trusted_fd
+                        */
+                       struct fd_event *trusted_fde;
+               } echo_handler;
+
                uint64_t num_requests;
                struct {
                        bool encrypted_passwords;