2006-09-15 22:32:43 +04:00
/*
* Unix SMB / CIFS implementation .
* client auto - generated by pidl . DO NOT MODIFY !
*/
# include "includes.h"
# include "librpc/gen_ndr/cli_initshutdown.h"
2008-01-09 13:59:11 +03:00
NTSTATUS rpccli_initshutdown_Init ( struct rpc_pipe_client * cli ,
TALLOC_CTX * mem_ctx ,
uint16_t * hostname ,
struct initshutdown_String * message ,
uint32_t timeout ,
uint8_t force_apps ,
uint8_t reboot ,
WERROR * werror )
2006-09-15 22:32:43 +04:00
{
struct initshutdown_Init r ;
NTSTATUS status ;
2008-01-08 20:07:55 +03:00
2006-09-15 22:32:43 +04:00
/* In parameters */
r . in . hostname = hostname ;
r . in . message = message ;
r . in . timeout = timeout ;
r . in . force_apps = force_apps ;
r . in . reboot = reboot ;
2008-01-08 20:07:55 +03:00
2008-01-09 13:59:11 +03:00
if ( DEBUGLEVEL > = 10 ) {
2006-09-20 02:39:15 +04:00
NDR_PRINT_IN_DEBUG ( initshutdown_Init , & r ) ;
2008-01-09 13:59:11 +03:00
}
2008-01-08 20:07:55 +03:00
2008-01-09 13:59:11 +03:00
status = cli_do_rpc_ndr ( cli ,
mem_ctx ,
PI_INITSHUTDOWN ,
& ndr_table_initshutdown ,
NDR_INITSHUTDOWN_INIT ,
& r ) ;
2008-01-08 20:07:55 +03:00
2007-02-16 17:50:57 +03:00
if ( ! NT_STATUS_IS_OK ( status ) ) {
2006-09-29 01:19:08 +04:00
return status ;
}
2008-01-08 20:07:55 +03:00
2008-01-09 13:59:11 +03:00
if ( DEBUGLEVEL > = 10 ) {
2006-09-20 02:39:15 +04:00
NDR_PRINT_OUT_DEBUG ( initshutdown_Init , & r ) ;
2008-01-09 13:59:11 +03:00
}
2008-01-08 20:07:55 +03:00
2006-09-15 22:32:43 +04:00
if ( NT_STATUS_IS_ERR ( status ) ) {
return status ;
}
2008-01-08 20:07:55 +03:00
2006-09-15 22:32:43 +04:00
/* Return variables */
2008-01-08 20:07:55 +03:00
2006-09-15 22:32:43 +04:00
/* Return result */
2007-12-03 20:19:20 +03:00
if ( werror ) {
* werror = r . out . result ;
}
2008-01-08 20:07:55 +03:00
2006-09-15 22:32:43 +04:00
return werror_to_ntstatus ( r . out . result ) ;
}
2008-01-09 13:59:11 +03:00
NTSTATUS rpccli_initshutdown_Abort ( struct rpc_pipe_client * cli ,
TALLOC_CTX * mem_ctx ,
uint16_t * server ,
WERROR * werror )
2006-09-15 22:32:43 +04:00
{
struct initshutdown_Abort r ;
NTSTATUS status ;
2008-01-08 20:07:55 +03:00
2006-09-15 22:32:43 +04:00
/* In parameters */
r . in . server = server ;
2008-01-08 20:07:55 +03:00
2008-01-09 13:59:11 +03:00
if ( DEBUGLEVEL > = 10 ) {
2006-09-20 02:39:15 +04:00
NDR_PRINT_IN_DEBUG ( initshutdown_Abort , & r ) ;
2008-01-09 13:59:11 +03:00
}
2008-01-08 20:07:55 +03:00
2008-01-09 13:59:11 +03:00
status = cli_do_rpc_ndr ( cli ,
mem_ctx ,
PI_INITSHUTDOWN ,
& ndr_table_initshutdown ,
NDR_INITSHUTDOWN_ABORT ,
& r ) ;
2008-01-08 20:07:55 +03:00
2007-02-16 17:50:57 +03:00
if ( ! NT_STATUS_IS_OK ( status ) ) {
2006-09-29 01:19:08 +04:00
return status ;
}
2008-01-08 20:07:55 +03:00
2008-01-09 13:59:11 +03:00
if ( DEBUGLEVEL > = 10 ) {
2006-09-20 02:39:15 +04:00
NDR_PRINT_OUT_DEBUG ( initshutdown_Abort , & r ) ;
2008-01-09 13:59:11 +03:00
}
2008-01-08 20:07:55 +03:00
2006-09-15 22:32:43 +04:00
if ( NT_STATUS_IS_ERR ( status ) ) {
return status ;
}
2008-01-08 20:07:55 +03:00
2006-09-15 22:32:43 +04:00
/* Return variables */
2008-01-08 20:07:55 +03:00
2006-09-15 22:32:43 +04:00
/* Return result */
2007-12-03 20:19:20 +03:00
if ( werror ) {
* werror = r . out . result ;
}
2008-01-08 20:07:55 +03:00
2006-09-15 22:32:43 +04:00
return werror_to_ntstatus ( r . out . result ) ;
}
2008-01-09 13:59:11 +03:00
NTSTATUS rpccli_initshutdown_InitEx ( struct rpc_pipe_client * cli ,
TALLOC_CTX * mem_ctx ,
uint16_t * hostname ,
struct initshutdown_String * message ,
uint32_t timeout ,
uint8_t force_apps ,
uint8_t reboot ,
uint32_t reason ,
WERROR * werror )
2006-09-15 22:32:43 +04:00
{
struct initshutdown_InitEx r ;
NTSTATUS status ;
2008-01-08 20:07:55 +03:00
2006-09-15 22:32:43 +04:00
/* In parameters */
r . in . hostname = hostname ;
r . in . message = message ;
r . in . timeout = timeout ;
r . in . force_apps = force_apps ;
r . in . reboot = reboot ;
r . in . reason = reason ;
2008-01-08 20:07:55 +03:00
2008-01-09 13:59:11 +03:00
if ( DEBUGLEVEL > = 10 ) {
2006-09-20 02:39:15 +04:00
NDR_PRINT_IN_DEBUG ( initshutdown_InitEx , & r ) ;
2008-01-09 13:59:11 +03:00
}
2008-01-08 20:07:55 +03:00
2008-01-09 13:59:11 +03:00
status = cli_do_rpc_ndr ( cli ,
mem_ctx ,
PI_INITSHUTDOWN ,
& ndr_table_initshutdown ,
NDR_INITSHUTDOWN_INITEX ,
& r ) ;
2008-01-08 20:07:55 +03:00
2007-02-16 17:50:57 +03:00
if ( ! NT_STATUS_IS_OK ( status ) ) {
2006-09-29 01:19:08 +04:00
return status ;
}
2008-01-08 20:07:55 +03:00
2008-01-09 13:59:11 +03:00
if ( DEBUGLEVEL > = 10 ) {
2006-09-20 02:39:15 +04:00
NDR_PRINT_OUT_DEBUG ( initshutdown_InitEx , & r ) ;
2008-01-09 13:59:11 +03:00
}
2008-01-08 20:07:55 +03:00
2006-09-15 22:32:43 +04:00
if ( NT_STATUS_IS_ERR ( status ) ) {
return status ;
}
2008-01-08 20:07:55 +03:00
2006-09-15 22:32:43 +04:00
/* Return variables */
2008-01-08 20:07:55 +03:00
2006-09-15 22:32:43 +04:00
/* Return result */
2007-12-03 20:19:20 +03:00
if ( werror ) {
* werror = r . out . result ;
}
2008-01-08 20:07:55 +03:00
2006-09-15 22:32:43 +04:00
return werror_to_ntstatus ( r . out . result ) ;
}