s4-ipv6: use "ip" instead of "ipv4" for servers
authorAndrew Tridgell <tridge@samba.org>
Thu, 12 May 2011 10:36:33 +0000 (12:36 +0200)
committerAndrew Tridgell <tridge@samba.org>
Mon, 6 Jun 2011 02:26:10 +0000 (12:26 +1000)
this allows stream_setup_socket() to work with both v4 and v6
addresses

source4/ldap_server/ldap_server.c
source4/rpc_server/dcerpc_server.c
source4/smb_server/smb_server.c
source4/web_server/web_server.c

index 605a4a3cc2932f025b18d0b50399f638cf9cac58..755eb441f40be162787b54312d90dc0e98bd8f2a 100644 (file)
@@ -815,7 +815,7 @@ static NTSTATUS add_socket(struct task_server *task,
 
        status = stream_setup_socket(task, task->event_ctx, lp_ctx,
                                     model_ops, &ldap_stream_nonpriv_ops,
-                                    "ipv4", address, &port, 
+                                    "ip", address, &port,
                                     lpcfg_socket_options(lp_ctx),
                                     ldap_service);
        if (!NT_STATUS_IS_OK(status)) {
@@ -830,7 +830,7 @@ static NTSTATUS add_socket(struct task_server *task,
                status = stream_setup_socket(task, task->event_ctx, lp_ctx,
                                             model_ops,
                                             &ldap_stream_nonpriv_ops,
-                                            "ipv4", address, &port, 
+                                            "ip", address, &port,
                                             lpcfg_socket_options(lp_ctx),
                                             ldap_service);
                if (!NT_STATUS_IS_OK(status)) {
@@ -852,7 +852,7 @@ static NTSTATUS add_socket(struct task_server *task,
                status = stream_setup_socket(task, task->event_ctx, lp_ctx,
                                             model_ops,
                                             &ldap_stream_nonpriv_ops,
-                                            "ipv4", address, &port, 
+                                            "ip", address, &port,
                                             lpcfg_socket_options(lp_ctx),
                                             ldap_service);
                if (!NT_STATUS_IS_OK(status)) {
@@ -866,7 +866,7 @@ static NTSTATUS add_socket(struct task_server *task,
                        status = stream_setup_socket(task, task->event_ctx, lp_ctx,
                                                     model_ops,
                                                     &ldap_stream_nonpriv_ops,
-                                                    "ipv4", address, &port,
+                                                    "ip", address, &port,
                                                     lpcfg_socket_options(lp_ctx),
                                                     ldap_service);
                        if (!NT_STATUS_IS_OK(status)) {
index 762221dc5b8ac3d7a63348f4f60f1864c331a5a6..01ce9891254ad20b6436da2cbb5336e293d5f3e0 100644 (file)
@@ -1648,7 +1648,7 @@ static NTSTATUS add_socket_rpc_tcp_iface(struct dcesrv_context *dce_ctx, struct
 
        status = stream_setup_socket(dcesrv_sock, event_ctx, dce_ctx->lp_ctx,
                                     model_ops, &dcesrv_stream_ops, 
-                                    "ipv4", address, &port, 
+                                    "ip", address, &port,
                                     lpcfg_socket_options(dce_ctx->lp_ctx),
                                     dcesrv_sock);
        if (!NT_STATUS_IS_OK(status)) {
index d21e5fbdb072895e654775aeeea2813849f334fc..d64a597d31fcab431e39e5b52328506643c9802d 100644 (file)
@@ -190,7 +190,7 @@ _PUBLIC_ NTSTATUS smbsrv_add_socket(TALLOC_CTX *mem_ctx,
                if (port == 0) continue;
                status = stream_setup_socket(mem_ctx, event_context, lp_ctx,
                                             model_ops, &smb_stream_ops, 
-                                            "ipv4", address, &port, 
+                                            "ip", address, &port,
                                             lpcfg_socket_options(lp_ctx),
                                             NULL);
                NT_STATUS_NOT_OK_RETURN(status);
index c43b2cfc7b17a268a8e9d6e86f45e1895eb703b4..74af4f9701f5e2b88305db10c50478e6d256ec91 100644 (file)
@@ -328,7 +328,7 @@ static void websrv_task_init(struct task_server *task)
                                                     task->event_ctx,
                                                     task->lp_ctx, model_ops,
                                                     &web_stream_ops, 
-                                                    "ipv4", address, 
+                                                    "ip", address,
                                                     &port, lpcfg_socket_options(task->lp_ctx),
                                                     task);
                        if (!NT_STATUS_IS_OK(status)) goto failed;