[NETAPI32]
authorEric Kohl <eric.kohl@reactos.org>
Tue, 26 Sep 2017 09:18:20 +0000 (09:18 +0000)
committerEric Kohl <eric.kohl@reactos.org>
Tue, 26 Sep 2017 09:18:20 +0000 (09:18 +0000)
Implement NetLogonSetServiceBits().

svn path=/trunk/; revision=75974

reactos/dll/win32/netapi32/netapi32.spec
reactos/dll/win32/netapi32/netlogon.c

index a07c78e..99131f6 100644 (file)
 @ stdcall NetLocalGroupSetInfo(wstr wstr long ptr ptr)
 @ stdcall NetLocalGroupSetMembers(wstr wstr long ptr long)
 @ stub NetLogonGetTimeServiceParentDomain
-@ stub NetLogonSetServiceBits
+@ stdcall NetLogonSetServiceBits(wstr long long)
 @ stdcall NetMessageBufferSend(wstr wstr wstr ptr long)
 @ stdcall NetMessageNameAdd(wstr wstr)
 @ stdcall NetMessageNameDel(wstr wstr)
index d9469ec..1133d57 100644 (file)
@@ -19,8 +19,10 @@ WINE_DEFAULT_DEBUG_CHANNEL(netapi32);
 
 /* FUNCTIONS *****************************************************************/
 
-handle_t __RPC_USER
-LOGONSRV_HANDLE_bind(LOGONSRV_HANDLE pszSystemName)
+handle_t
+__RPC_USER
+LOGONSRV_HANDLE_bind(
+    LOGONSRV_HANDLE pszSystemName)
 {
     handle_t hBinding = NULL;
     LPWSTR pszStringBinding;
@@ -58,9 +60,11 @@ LOGONSRV_HANDLE_bind(LOGONSRV_HANDLE pszSystemName)
 }
 
 
-void __RPC_USER
-LOGONSRV_HANDLE_unbind(LOGONSRV_HANDLE pszSystemName,
-                       handle_t hBinding)
+void
+__RPC_USER
+LOGONSRV_HANDLE_unbind(
+    LOGONSRV_HANDLE pszSystemName,
+    handle_t hBinding)
 {
     RPC_STATUS status;
 
@@ -74,6 +78,8 @@ LOGONSRV_HANDLE_unbind(LOGONSRV_HANDLE pszSystemName,
 }
 
 
+/* PUBLIC FUNCTIONS **********************************************************/
+
 DWORD
 WINAPI
 DsAddressToSiteNamesA(
@@ -645,4 +651,32 @@ NetGetDCName(
     return NERR_DCNotFound;
 }
 
+
+NTSTATUS
+WINAPI
+NetLogonSetServiceBits(
+    _In_ LPWSTR ServerName,
+    _In_ DWORD ServiceBitsOfInterest,
+    _In_ DWORD ServiceBits)
+{
+    NTSTATUS Status;
+
+    TRACE("NetLogonSetServiceBits(%s 0x%lx 0x%lx)\n",
+          debugstr_w(ServerName), ServiceBitsOfInterest, ServiceBits);
+
+    RpcTryExcept
+    {
+        Status = NetrLogonSetServiceBits(ServerName,
+                                         ServiceBitsOfInterest,
+                                         ServiceBits);
+    }
+    RpcExcept(EXCEPTION_EXECUTE_HANDLER)
+    {
+        Status = RpcExceptionCode();
+    }
+    RpcEndExcept;
+
+    return Status;
+}
+
 /* EOF */