summaryrefslogtreecommitdiff
path: root/source3
diff options
context:
space:
mode:
authorGünther Deschner <gd@samba.org>2007-12-03 18:40:36 +0100
committerGünther Deschner <gd@samba.org>2007-12-03 18:43:19 +0100
commit6f1b4eb8695559049ce7b5cab20b42f7762dbf2b (patch)
tree0038c9b23e8040fae90dd6133c346f5bef8b1032 /source3
parent6b37d8e627a2b983a5801ec533e536dd67e5f0e5 (diff)
downloadsamba-6f1b4eb8695559049ce7b5cab20b42f7762dbf2b.tar.gz
samba-6f1b4eb8695559049ce7b5cab20b42f7762dbf2b.tar.bz2
samba-6f1b4eb8695559049ce7b5cab20b42f7762dbf2b.zip
Fix shutdown callers.
Guenther (This used to be commit de2fdc6b5a78932f8ea5cf4c4715296f18dae4d3)
Diffstat (limited to 'source3')
-rw-r--r--source3/utils/net_rpc.c13
1 files changed, 7 insertions, 6 deletions
diff --git a/source3/utils/net_rpc.c b/source3/utils/net_rpc.c
index 97dcf2c526..0f58c05c51 100644
--- a/source3/utils/net_rpc.c
+++ b/source3/utils/net_rpc.c
@@ -5091,7 +5091,7 @@ static NTSTATUS rpc_shutdown_abort_internals(const DOM_SID *domain_sid,
{
NTSTATUS result = NT_STATUS_UNSUCCESSFUL;
- result = rpccli_initshutdown_Abort(pipe_hnd, mem_ctx, NULL);
+ result = rpccli_initshutdown_Abort(pipe_hnd, mem_ctx, NULL, NULL);
if (NT_STATUS_IS_OK(result)) {
d_printf("\nShutdown successfully aborted\n");
@@ -5128,7 +5128,7 @@ static NTSTATUS rpc_reg_shutdown_abort_internals(const DOM_SID *domain_sid,
{
NTSTATUS result = NT_STATUS_UNSUCCESSFUL;
- result = rpccli_winreg_AbortSystemShutdown(pipe_hnd, mem_ctx, NULL);
+ result = rpccli_winreg_AbortSystemShutdown(pipe_hnd, mem_ctx, NULL, NULL);
if (NT_STATUS_IS_OK(result)) {
d_printf("\nShutdown successfully aborted\n");
@@ -5207,7 +5207,7 @@ NTSTATUS rpc_init_shutdown_internals(const DOM_SID *domain_sid,
/* create an entry */
result = rpccli_initshutdown_Init(pipe_hnd, mem_ctx, NULL,
- &msg_string, timeout, opt_force, opt_reboot);
+ &msg_string, timeout, opt_force, opt_reboot, NULL);
if (NT_STATUS_IS_OK(result)) {
d_printf("\nShutdown of remote machine succeeded\n");
@@ -5247,6 +5247,7 @@ NTSTATUS rpc_reg_shutdown_internals(const DOM_SID *domain_sid,
struct initshutdown_String msg_string;
struct initshutdown_String_sub s;
NTSTATUS result;
+ WERROR werr;
if (opt_comment) {
msg = opt_comment;
@@ -5260,16 +5261,16 @@ NTSTATUS rpc_reg_shutdown_internals(const DOM_SID *domain_sid,
/* create an entry */
result = rpccli_winreg_InitiateSystemShutdown(pipe_hnd, mem_ctx, NULL,
- &msg_string, timeout, opt_force, opt_reboot);
+ &msg_string, timeout, opt_force, opt_reboot, &werr);
if (NT_STATUS_IS_OK(result)) {
d_printf("\nShutdown of remote machine succeeded\n");
} else {
d_fprintf(stderr, "\nShutdown of remote machine failed\n");
- if ( W_ERROR_EQUAL(ntstatus_to_werror(result),WERR_MACHINE_LOCKED) )
+ if ( W_ERROR_EQUAL(werr, WERR_MACHINE_LOCKED) )
d_fprintf(stderr, "\nMachine locked, use -f switch to force\n");
else
- d_fprintf(stderr, "\nresult was: %s\n", nt_errstr(result));
+ d_fprintf(stderr, "\nresult was: %s\n", dos_errstr(werr));
}
return result;