Use rpccli_srvsvc_NetRemoteTOD() in rpcclient.
authorGünther Deschner <gd@samba.org>
Wed, 5 Mar 2008 09:38:13 +0000 (10:38 +0100)
committerGünther Deschner <gd@samba.org>
Wed, 5 Mar 2008 09:38:13 +0000 (10:38 +0100)
Guenther
(This used to be commit 5e9d8cdc948b678e5aa6e04ee13635376b7306f5)

source3/rpcclient/cmd_srvsvc.c

index 4b3601a5ff6966c6ac9d0ddf8ec70d70f1470632..2e84f0498f46b980205ef08ffd821991173fd33a 100644 (file)
@@ -402,9 +402,10 @@ static WERROR cmd_srvsvc_net_remote_tod(struct rpc_pipe_client *cli,
                                           TALLOC_CTX *mem_ctx,
                                           int argc, const char **argv)
 {
-       TIME_OF_DAY_INFO tod;
+       struct srvsvc_NetRemoteTODInfo *tod = NULL;
        fstring srv_name_slash;
        WERROR result;
+       NTSTATUS status;
 
        if (argc > 1) {
                printf("Usage: %s\n", argv[0]);
@@ -412,8 +413,14 @@ static WERROR cmd_srvsvc_net_remote_tod(struct rpc_pipe_client *cli,
        }
 
        fstr_sprintf(srv_name_slash, "\\\\%s", cli->cli->desthost);
-       result = rpccli_srvsvc_net_remote_tod(
-               cli, mem_ctx, srv_name_slash, &tod);
+       status = rpccli_srvsvc_NetRemoteTOD(cli, mem_ctx,
+                                           srv_name_slash,
+                                           &tod,
+                                           &result);
+       if (!NT_STATUS_IS_OK(status)) {
+               result = ntstatus_to_werror(status);
+               goto done;
+       }
 
        if (!W_ERROR_IS_OK(result))
                goto done;