summaryrefslogtreecommitdiff
path: root/source3/rpc_server/srv_wkssvc.c
diff options
context:
space:
mode:
authorJim McDonough <jmcd@samba.org>2003-02-14 00:48:28 +0000
committerJim McDonough <jmcd@samba.org>2003-02-14 00:48:28 +0000
commit49d3f7bc81d3ce96513128f3e504ae1228e53d68 (patch)
tree3dcf850272d78fef0d576a941bb0ac08d1ff5c01 /source3/rpc_server/srv_wkssvc.c
parent3807a1dadf1905567d70a7dd2b6344b884cf0ef7 (diff)
downloadsamba-49d3f7bc81d3ce96513128f3e504ae1228e53d68.tar.gz
samba-49d3f7bc81d3ce96513128f3e504ae1228e53d68.tar.bz2
samba-49d3f7bc81d3ce96513128f3e504ae1228e53d68.zip
merge from HEAD - enable dynamic RPC modules
(This used to be commit d9c485b01017594d113502f9de2248d6c120cfa3)
Diffstat (limited to 'source3/rpc_server/srv_wkssvc.c')
-rw-r--r--source3/rpc_server/srv_wkssvc.c24
1 files changed, 13 insertions, 11 deletions
diff --git a/source3/rpc_server/srv_wkssvc.c b/source3/rpc_server/srv_wkssvc.c
index c783becbbe..1fed2cc6db 100644
--- a/source3/rpc_server/srv_wkssvc.c
+++ b/source3/rpc_server/srv_wkssvc.c
@@ -3,7 +3,8 @@
* RPC Pipe client / server routines
* Copyright (C) Andrew Tridgell 1992-1997,
* Copyright (C) Luke Kenneth Casson Leighton 1996-1997,
- * Copyright (C) Paul Ashton 1997.
+ * Copyright (C) Paul Ashton 1997,
+ * Copyright (C) Anthony Liguori 2003.
*
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
@@ -58,16 +59,17 @@ static BOOL api_wks_query_info(pipes_struct *p)
/*******************************************************************
\PIPE\wkssvc commands
********************************************************************/
-static struct api_struct api_wks_cmds[] =
-{
- { "WKS_Q_QUERY_INFO", WKS_QUERY_INFO, api_wks_query_info },
- { NULL , 0 , NULL }
-};
-/*******************************************************************
- receives a wkssvc pipe and responds.
- ********************************************************************/
-BOOL api_wkssvc_rpc(pipes_struct *p)
+#ifdef RPC_WKS_DYNAMIC
+int rpc_pipe_init(void)
+#else
+int rpc_wks_init(void)
+#endif
{
- return api_rpcTNP(p, "api_wkssvc_rpc", api_wks_cmds);
+ static struct api_struct api_wks_cmds[] =
+ {
+ { "WKS_Q_QUERY_INFO", WKS_QUERY_INFO, api_wks_query_info }
+ };
+ return rpc_pipe_register_commands("wkssvc", "ntsvcs", api_wks_cmds,
+ sizeof(api_wks_cmds) / sizeof(struct api_struct));
}