s3-net: pass down ndr_interface_table to connect_dst_pipe().
authorGünther Deschner <gd@samba.org>
Fri, 17 May 2013 14:02:59 +0000 (16:02 +0200)
committerStefan Metzmacher <metze@samba.org>
Sat, 3 Aug 2013 07:07:55 +0000 (09:07 +0200)
Guenther

Signed-off-by: Günther Deschner <gd@samba.org>
Reviewed-by: Stefan Metzmacher <metze@samba.org>
source3/utils/net_proto.h
source3/utils/net_rpc.c
source3/utils/net_rpc_printer.c
source3/utils/net_util.c

index 3f99e14e6e8be3707fe2cb67b0a81c8ed4f6b4c8..03fb31290fc0d45c1eb3f074c73010e8c03a1c47 100644 (file)
@@ -416,7 +416,7 @@ NTSTATUS connect_to_ipc_anonymous(struct net_context *c,
                                const char *server_name);
 NTSTATUS connect_dst_pipe(struct net_context *c, struct cli_state **cli_dst,
                          struct rpc_pipe_client **pp_pipe_hnd,
-                         const struct ndr_syntax_id *interface);
+                         const struct ndr_interface_table *table);
 int net_use_krb_machine_account(struct net_context *c);
 int net_use_machine_account(struct net_context *c);
 bool net_find_server(struct net_context *c,
index 870ad2287f2a9878a0d31b5cec92756f5913e615..e59a22325d43c2891b805ba93e9ba7f549a97310 100644 (file)
@@ -3619,7 +3619,7 @@ static NTSTATUS rpc_share_migrate_shares_internals(struct net_context *c,
 
        /* connect destination PI_SRVSVC */
         nt_status = connect_dst_pipe(c, &cli_dst, &srvsvc_pipe,
-                                    &ndr_table_srvsvc.syntax_id);
+                                    &ndr_table_srvsvc);
         if (!NT_STATUS_IS_OK(nt_status))
                 return nt_status;
 
@@ -4105,7 +4105,7 @@ static NTSTATUS rpc_share_migrate_security_internals(struct net_context *c,
 
        /* connect destination PI_SRVSVC */
         nt_status = connect_dst_pipe(c, &cli_dst, &srvsvc_pipe,
-                                    &ndr_table_srvsvc.syntax_id);
+                                    &ndr_table_srvsvc);
         if (!NT_STATUS_IS_OK(nt_status))
                 return nt_status;
 
index 9743d08e0c172cbbc8f0fe6ebb3e49a2e9ae9574..3ed97a778eaf5a2d4330df1a1fee0e0cd1b12e3f 100644 (file)
@@ -1577,7 +1577,7 @@ NTSTATUS rpc_printer_migrate_security_internals(struct net_context *c,
 
        /* connect destination PI_SPOOLSS */
        nt_status = connect_dst_pipe(c, &cli_dst, &pipe_hnd_dst,
-                                    &ndr_table_spoolss.syntax_id);
+                                    &ndr_table_spoolss);
        if (!NT_STATUS_IS_OK(nt_status)) {
                return nt_status;
        }
@@ -1729,7 +1729,7 @@ NTSTATUS rpc_printer_migrate_forms_internals(struct net_context *c,
 
        /* connect destination PI_SPOOLSS */
        nt_status = connect_dst_pipe(c, &cli_dst, &pipe_hnd_dst,
-                                    &ndr_table_spoolss.syntax_id);
+                                    &ndr_table_spoolss);
        if (!NT_STATUS_IS_OK(nt_status)) {
                return nt_status;
        }
@@ -1906,7 +1906,7 @@ NTSTATUS rpc_printer_migrate_drivers_internals(struct net_context *c,
        DEBUG(3,("copying printer-drivers\n"));
 
        nt_status = connect_dst_pipe(c, &cli_dst, &pipe_hnd_dst,
-                                    &ndr_table_spoolss.syntax_id);
+                                    &ndr_table_spoolss);
        if (!NT_STATUS_IS_OK(nt_status)) {
                return nt_status;
        }
@@ -2125,7 +2125,7 @@ NTSTATUS rpc_printer_migrate_printers_internals(struct net_context *c,
 
        /* connect destination PI_SPOOLSS */
        nt_status = connect_dst_pipe(c, &cli_dst, &pipe_hnd_dst,
-                                    &ndr_table_spoolss.syntax_id);
+                                    &ndr_table_spoolss);
        if (!NT_STATUS_IS_OK(nt_status)) {
                return nt_status;
        }
@@ -2300,7 +2300,7 @@ NTSTATUS rpc_printer_migrate_settings_internals(struct net_context *c,
 
        /* connect destination PI_SPOOLSS */
        nt_status = connect_dst_pipe(c, &cli_dst, &pipe_hnd_dst,
-                                    &ndr_table_spoolss.syntax_id);
+                                    &ndr_table_spoolss);
        if (!NT_STATUS_IS_OK(nt_status)) {
                return nt_status;
        }
index 9c4a77eff47fd62e13e7b81974f91aa9db5b00cd..a4282ec4217aac96d9741ad83eedbea105bd49be 100644 (file)
@@ -231,7 +231,7 @@ NTSTATUS connect_to_ipc_anonymous(struct net_context *c,
  **/
 NTSTATUS connect_dst_pipe(struct net_context *c, struct cli_state **cli_dst,
                          struct rpc_pipe_client **pp_pipe_hnd,
-                         const struct ndr_syntax_id *interface)
+                         const struct ndr_interface_table *table)
 {
        NTSTATUS nt_status;
        char *server_name = SMB_STRDUP("127.0.0.1");
@@ -256,7 +256,7 @@ NTSTATUS connect_dst_pipe(struct net_context *c, struct cli_state **cli_dst,
                return nt_status;
        }
 
-       nt_status = cli_rpc_pipe_open_noauth(cli_tmp, interface,
+       nt_status = cli_rpc_pipe_open_noauth(cli_tmp, &table->syntax_id,
                                             &pipe_hnd);
        if (!NT_STATUS_IS_OK(nt_status)) {
                DEBUG(0, ("couldn't not initialize pipe\n"));