ReactOS
0.4.16-dev-297-gc569aee
Toggle main menu visibility
Main Page
Related Pages
Modules
Namespaces
Namespace List
Namespace Members
All
_
a
b
c
d
e
f
g
h
i
l
m
n
o
p
r
s
t
u
v
w
x
Functions
_
a
b
c
d
e
f
g
h
i
l
m
o
p
r
s
t
u
v
w
Variables
_
c
d
e
f
g
h
i
l
n
o
p
s
t
u
x
Typedefs
_
a
b
c
d
e
f
g
h
i
l
m
o
p
r
s
t
u
v
w
x
Enumerations
_
c
d
f
i
l
m
o
p
s
t
w
x
Enumerator
a
b
c
d
e
f
g
h
i
m
n
o
p
r
s
t
u
v
w
x
Classes
Class List
Class Index
Class Hierarchy
Class Members
All
_
a
b
c
d
e
f
g
h
i
j
k
l
m
n
o
p
q
r
s
t
u
v
w
x
y
z
~
Functions
_
a
b
c
d
e
f
g
h
i
j
k
l
m
n
o
p
q
r
s
t
u
v
w
x
y
z
~
Variables
_
a
b
c
d
e
f
g
h
i
j
k
l
m
n
o
p
q
r
s
t
u
v
w
x
y
z
Typedefs
_
a
b
c
d
e
f
g
h
i
k
l
m
n
o
p
q
r
s
t
u
v
w
x
y
z
Enumerations
_
a
b
c
d
e
f
h
i
k
l
m
n
o
p
r
s
t
u
v
w
z
Enumerator
_
a
b
c
d
e
f
g
h
i
k
l
m
n
o
p
q
r
s
t
u
v
w
x
y
z
Properties
_
a
b
c
d
e
f
g
h
i
j
k
l
m
n
o
p
q
r
s
t
u
v
w
x
z
Related Functions
_
a
b
c
d
e
f
g
h
i
l
m
n
o
p
q
r
s
t
v
x
Files
File List
File Members
All
$
_
a
b
c
d
e
f
g
h
i
j
k
l
m
n
o
p
q
r
s
t
u
v
w
x
y
z
Functions
$
_
a
b
c
d
e
f
g
h
i
j
k
l
m
n
o
p
q
r
s
t
u
v
w
x
y
z
Variables
$
_
a
b
c
d
e
f
g
h
i
j
k
l
m
n
o
p
q
r
s
t
u
v
w
x
y
z
Typedefs
_
a
b
c
d
e
f
g
h
i
j
k
l
m
n
o
p
q
r
s
t
u
v
w
x
y
z
Enumerations
_
a
b
c
d
e
f
g
h
i
j
k
l
m
n
o
p
q
r
s
t
u
v
w
x
y
z
Enumerator
_
a
b
c
d
e
f
g
h
i
j
k
l
m
n
o
p
q
r
s
t
u
v
w
x
y
z
Macros
_
a
b
c
d
e
f
g
h
i
j
k
l
m
n
o
p
q
r
s
t
u
v
w
x
y
z
Examples
rpc.c
Go to the documentation of this file.
1
#define WIN32_NO_STATUS
2
#define _INC_WINDOWS
3
#define COM_NO_WINDOWS_H
4
#include <stdarg.h>
5
#include <
windef.h
>
6
#include <
winbase.h
>
7
#include <dnsrslvr_c.h>
8
9
#define NDEBUG
10
#include <debug.h>
11
12
handle_t
__RPC_USER
13
DNSRSLVR_HANDLE_bind
(
DNSRSLVR_HANDLE
pszMachineName)
14
{
15
handle_t
hBinding
=
NULL
;
16
LPWSTR
pszStringBinding;
17
RPC_STATUS
Status
;
18
19
DPRINT
(
"DNSRSLVR_HANDLE_bind(%S)\n"
, pszMachineName);
20
21
Status
=
RpcStringBindingComposeW
(
NULL
,
22
L
"ncalrpc"
,
23
pszMachineName,
24
L
"DNSResolver"
,
25
NULL
,
26
&pszStringBinding);
27
if
(
Status
!=
RPC_S_OK
)
28
{
29
DPRINT1
(
"RpcStringBindingCompose returned 0x%x\n"
,
Status
);
30
return
NULL
;
31
}
32
33
/* Set the binding handle that will be used to bind to the server. */
34
Status
=
RpcBindingFromStringBindingW
(pszStringBinding,
35
&
hBinding
);
36
if
(
Status
!=
RPC_S_OK
)
37
{
38
DPRINT1
(
"RpcBindingFromStringBinding returned 0x%x\n"
,
Status
);
39
}
40
41
Status
=
RpcStringFreeW
(&pszStringBinding);
42
if
(
Status
!=
RPC_S_OK
)
43
{
44
DPRINT1
(
"RpcStringFree returned 0x%x\n"
,
Status
);
45
}
46
47
return
hBinding
;
48
}
49
50
void
__RPC_USER
51
DNSRSLVR_HANDLE_unbind
(
DNSRSLVR_HANDLE
pszMachineName,
52
handle_t
hBinding
)
53
{
54
RPC_STATUS
Status
;
55
56
DPRINT
(
"DNSRSLVR_HANDLE_unbind(%S)\n"
, pszMachineName);
57
58
Status
=
RpcBindingFree
(&
hBinding
);
59
if
(
Status
!=
RPC_S_OK
)
60
{
61
DPRINT1
(
"RpcBindingFree returned 0x%x\n"
,
Status
);
62
}
63
}
64
65
void
__RPC_FAR
*
__RPC_USER
66
midl_user_allocate
(
SIZE_T
len
)
67
{
68
return
HeapAlloc
(
GetProcessHeap
(),
HEAP_ZERO_MEMORY
,
len
);
69
}
70
71
void
__RPC_USER
72
midl_user_free
(
void
__RPC_FAR
*
ptr
)
73
{
74
HeapFree
(
GetProcessHeap
(), 0,
ptr
);
75
}
DPRINT1
#define DPRINT1
Definition:
precomp.h:8
hBinding
handle_t hBinding
Definition:
ctx_c.c:54
NULL
#define NULL
Definition:
types.h:112
GetProcessHeap
#define GetProcessHeap()
Definition:
compat.h:736
HeapAlloc
#define HeapAlloc
Definition:
compat.h:733
HeapFree
#define HeapFree(x, y, z)
Definition:
compat.h:735
HEAP_ZERO_MEMORY
#define HEAP_ZERO_MEMORY
Definition:
compat.h:134
DNSRSLVR_HANDLE_unbind
void __RPC_USER DNSRSLVR_HANDLE_unbind(DNSRSLVR_HANDLE pszMachineName, handle_t hBinding)
Definition:
rpc.c:51
DNSRSLVR_HANDLE_bind
handle_t __RPC_USER DNSRSLVR_HANDLE_bind(DNSRSLVR_HANDLE pszMachineName)
Definition:
rpc.c:13
DNSRSLVR_HANDLE
LPWSTR DNSRSLVR_HANDLE
Definition:
dnsrslvr.idl:17
Status
Status
Definition:
gdiplustypes.h:25
len
GLenum GLsizei len
Definition:
glext.h:6722
void
Definition:
nsiface.idl:2307
ptr
static PVOID ptr
Definition:
dispmode.c:27
L
#define L(x)
Definition:
ntvdm.h:50
RpcBindingFromStringBindingW
RPC_STATUS WINAPI RpcBindingFromStringBindingW(RPC_WSTR StringBinding, RPC_BINDING_HANDLE *Binding)
Definition:
rpc_binding.c:880
RpcStringBindingComposeW
RPC_STATUS WINAPI RpcStringBindingComposeW(RPC_WSTR ObjUuid, RPC_WSTR Protseq, RPC_WSTR NetworkAddr, RPC_WSTR Endpoint, RPC_WSTR Options, RPC_WSTR *StringBinding)
Definition:
rpc_binding.c:510
RpcBindingFree
RPC_STATUS WINAPI RpcBindingFree(RPC_BINDING_HANDLE *Binding)
Definition:
rpc_binding.c:787
RPC_S_OK
#define RPC_S_OK
Definition:
rpcnterr.h:22
RpcStringFreeW
RPC_STATUS WINAPI RpcStringFreeW(RPC_WSTR *String)
Definition:
rpcrt4_main.c:175
midl_user_free
#define midl_user_free
Definition:
rpc.h:45
__RPC_FAR
#define __RPC_FAR
Definition:
rpc.h:56
RPC_STATUS
long RPC_STATUS
Definition:
rpc.h:52
__RPC_USER
#define __RPC_USER
Definition:
rpc.h:65
midl_user_allocate
#define midl_user_allocate
Definition:
rpc.h:44
DPRINT
#define DPRINT
Definition:
sndvol32.h:73
SIZE_T
ULONG_PTR SIZE_T
Definition:
typedefs.h:80
winbase.h
windef.h
LPWSTR
WCHAR * LPWSTR
Definition:
xmlstorage.h:184
dll
win32
dnsapi
rpc.c
Generated on Tue Nov 26 2024 06:10:30 for ReactOS by
1.9.6