Artifact c14904c7a961f355b2234255e8441bb3d6ec164f:
- File
src/win32/rpcdcep.d
-
2015-05-05 06:49:05
- part of checkin
[9b639cf2d6]
on branch trunk
- Working version for update to 2.067.
The problem was __gshared. Replacing it with TLS fixed the issue. Remaining problem is that "hack.d"'s CloseHandle hack is not working anymore.
(user: kinaba) [annotate]
-
2015-05-05 06:49:05
- part of checkin
[9b639cf2d6]
on branch trunk
- Working version for update to 2.067.
0000: 2f 2a 2a 2a 2a 2a 2a 2a 2a 2a 2a 2a 2a 2a 2a 2a /***************
0010: 2a 2a 2a 2a 2a 2a 2a 2a 2a 2a 2a 2a 2a 2a 2a 2a ****************
0020: 2a 2a 2a 2a 2a 2a 2a 2a 2a 2a 2a 2a 2a 2a 2a 2a ****************
0030: 2a 2a 2a 2a 2a 2a 2a 2a 2a 2a 2a 2a 2a 2a 2a 2a ****************
0040: 2a 2a 2a 2a 2a 2a 2a 2a 5c 0d 0a 2a 20 20 20 20 ********\..*
0050: 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20
0060: 20 20 20 20 20 20 20 20 20 20 20 72 70 63 64 63 rpcdc
0070: 65 70 2e 64 20 20 20 20 20 20 20 20 20 20 20 20 ep.d
0080: 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20
0090: 20 20 20 2a 0d 0a 2a 20 20 20 20 20 20 20 20 20 *..*
00a0: 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20
00b0: 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20
00c0: 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20
00d0: 20 20 20 20 20 20 20 20 20 20 20 20 20 20 2a 0d *.
00e0: 0a 2a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 .*
00f0: 20 20 20 20 20 20 20 20 20 57 69 6e 64 6f 77 73 Windows
0100: 20 41 50 49 20 68 65 61 64 65 72 20 6d 6f 64 75 API header modu
0110: 6c 65 20 20 20 20 20 20 20 20 20 20 20 20 20 20 le
0120: 20 20 20 20 20 20 20 20 20 2a 0d 0a 2a 20 20 20 *..*
0130: 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20
0140: 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20
0150: 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20
0160: 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20
0170: 20 20 20 20 2a 0d 0a 2a 20 20 20 20 20 20 20 20 *..*
0180: 20 20 20 20 20 20 20 20 20 54 72 61 6e 73 6c 61 Transla
0190: 74 65 64 20 66 72 6f 6d 20 4d 69 6e 47 57 20 57 ted from MinGW W
01a0: 69 6e 64 6f 77 73 20 68 65 61 64 65 72 73 20 20 indows headers
01b0: 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 2a *
01c0: 0d 0a 2a 20 20 20 20 20 20 20 20 20 20 20 20 20 ..*
01d0: 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20
01e0: 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20
01f0: 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20
0200: 20 20 20 20 20 20 20 20 20 20 2a 0d 0a 2a 20 20 *..*
0210: 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20
0220: 20 20 20 20 20 50 6c 61 63 65 64 20 69 6e 74 6f Placed into
0230: 20 70 75 62 6c 69 63 20 64 6f 6d 61 69 6e 20 20 public domain
0240: 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20
0250: 20 20 20 20 20 2a 0d 0a 5c 2a 2a 2a 2a 2a 2a 2a *..\*******
0260: 2a 2a 2a 2a 2a 2a 2a 2a 2a 2a 2a 2a 2a 2a 2a 2a ****************
0270: 2a 2a 2a 2a 2a 2a 2a 2a 2a 2a 2a 2a 2a 2a 2a 2a ****************
0280: 2a 2a 2a 2a 2a 2a 2a 2a 2a 2a 2a 2a 2a 2a 2a 2a ****************
0290: 2a 2a 2a 2a 2a 2a 2a 2a 2a 2a 2a 2a 2a 2a 2a 2a ****************
02a0: 2f 0d 0a 6d 6f 64 75 6c 65 20 77 69 6e 33 32 2e /..module win32.
02b0: 72 70 63 64 63 65 70 3b 0d 0a 0d 0a 70 72 69 76 rpcdcep;....priv
02c0: 61 74 65 20 69 6d 70 6f 72 74 20 77 69 6e 33 32 ate import win32
02d0: 2e 62 61 73 65 74 79 70 73 3b 0d 0a 70 72 69 76 .basetyps;..priv
02e0: 61 74 65 20 69 6d 70 6f 72 74 20 77 69 6e 33 32 ate import win32
02f0: 2e 77 33 32 61 70 69 3b 0d 0a 70 72 69 76 61 74 .w32api;..privat
0300: 65 20 69 6d 70 6f 72 74 20 77 69 6e 33 32 2e 77 e import win32.w
0310: 69 6e 64 65 66 3b 0d 0a 0d 0a 6d 69 78 69 6e 20 indef;....mixin
0320: 44 45 43 4c 41 52 45 5f 48 41 4e 44 4c 45 21 28 DECLARE_HANDLE!(
0330: 22 49 5f 52 50 43 5f 48 41 4e 44 4c 45 22 29 3b "I_RPC_HANDLE");
0340: 0d 0a 61 6c 69 61 73 20 6c 6f 6e 67 20 52 50 43 ..alias long RPC
0350: 5f 53 54 41 54 55 53 3b 0d 0a 0d 0a 63 6f 6e 73 _STATUS;....cons
0360: 74 20 52 50 43 5f 4e 43 41 5f 46 4c 41 47 53 5f t RPC_NCA_FLAGS_
0370: 44 45 46 41 55 4c 54 3d 30 3b 0d 0a 63 6f 6e 73 DEFAULT=0;..cons
0380: 74 20 52 50 43 5f 4e 43 41 5f 46 4c 41 47 53 5f t RPC_NCA_FLAGS_
0390: 49 44 45 4d 50 4f 54 45 4e 54 3d 31 3b 0d 0a 63 IDEMPOTENT=1;..c
03a0: 6f 6e 73 74 20 52 50 43 5f 4e 43 41 5f 46 4c 41 onst RPC_NCA_FLA
03b0: 47 53 5f 42 52 4f 41 44 43 41 53 54 3d 32 3b 0d GS_BROADCAST=2;.
03c0: 0a 63 6f 6e 73 74 20 52 50 43 5f 4e 43 41 5f 46 .const RPC_NCA_F
03d0: 4c 41 47 53 5f 4d 41 59 42 45 3d 34 3b 0d 0a 63 LAGS_MAYBE=4;..c
03e0: 6f 6e 73 74 20 52 50 43 46 4c 47 5f 41 53 59 4e onst RPCFLG_ASYN
03f0: 43 48 52 4f 4e 4f 55 53 3d 30 78 34 30 30 30 30 CHRONOUS=0x40000
0400: 30 30 30 3b 0d 0a 63 6f 6e 73 74 20 52 50 43 46 000;..const RPCF
0410: 4c 47 5f 49 4e 50 55 54 5f 53 59 4e 43 48 52 4f LG_INPUT_SYNCHRO
0420: 4e 4f 55 53 3d 30 78 32 30 30 30 30 30 30 30 3b NOUS=0x20000000;
0430: 0d 0a 63 6f 6e 73 74 20 52 50 43 5f 46 4c 41 47 ..const RPC_FLAG
0440: 53 5f 56 41 4c 49 44 5f 42 49 54 3d 30 78 38 30 S_VALID_BIT=0x80
0450: 30 30 3b 0d 0a 0d 0a 63 6f 6e 73 74 20 54 52 41 00;....const TRA
0460: 4e 53 50 4f 52 54 5f 54 59 50 45 5f 43 4e 3d 31 NSPORT_TYPE_CN=1
0470: 3b 0d 0a 63 6f 6e 73 74 20 54 52 41 4e 53 50 4f ;..const TRANSPO
0480: 52 54 5f 54 59 50 45 5f 44 47 3d 32 3b 0d 0a 63 RT_TYPE_DG=2;..c
0490: 6f 6e 73 74 20 54 52 41 4e 53 50 4f 52 54 5f 54 onst TRANSPORT_T
04a0: 59 50 45 5f 4c 50 43 3d 34 3b 0d 0a 63 6f 6e 73 YPE_LPC=4;..cons
04b0: 74 20 54 52 41 4e 53 50 4f 52 54 5f 54 59 50 45 t TRANSPORT_TYPE
04c0: 5f 57 4d 53 47 3d 38 3b 0d 0a 0d 0a 73 74 72 75 _WMSG=8;....stru
04d0: 63 74 20 52 50 43 5f 56 45 52 53 49 4f 4e 20 7b ct RPC_VERSION {
04e0: 0d 0a 09 75 73 68 6f 72 74 20 4d 61 6a 6f 72 56 ...ushort MajorV
04f0: 65 72 73 69 6f 6e 3b 0d 0a 09 75 73 68 6f 72 74 ersion;...ushort
0500: 20 4d 69 6e 6f 72 56 65 72 73 69 6f 6e 3b 0d 0a MinorVersion;..
0510: 7d 0d 0a 73 74 72 75 63 74 20 52 50 43 5f 53 59 }..struct RPC_SY
0520: 4e 54 41 58 5f 49 44 45 4e 54 49 46 49 45 52 20 NTAX_IDENTIFIER
0530: 7b 0d 0a 09 47 55 49 44 20 20 20 20 20 20 20 20 {...GUID
0540: 53 79 6e 74 61 78 47 55 49 44 3b 0d 0a 09 52 50 SyntaxGUID;...RP
0550: 43 5f 56 45 52 53 49 4f 4e 20 53 79 6e 74 61 78 C_VERSION Syntax
0560: 56 65 72 73 69 6f 6e 3b 0d 0a 7d 0d 0a 61 6c 69 Version;..}..ali
0570: 61 73 20 52 50 43 5f 53 59 4e 54 41 58 5f 49 44 as RPC_SYNTAX_ID
0580: 45 4e 54 49 46 49 45 52 2a 20 50 52 50 43 5f 53 ENTIFIER* PRPC_S
0590: 59 4e 54 41 58 5f 49 44 45 4e 54 49 46 49 45 52 YNTAX_IDENTIFIER
05a0: 3b 0d 0a 0d 0a 73 74 72 75 63 74 20 52 50 43 5f ;....struct RPC_
05b0: 4d 45 53 53 41 47 45 20 7b 0d 0a 09 48 41 4e 44 MESSAGE {...HAND
05c0: 4c 45 20 48 61 6e 64 6c 65 3b 0d 0a 09 75 69 6e LE Handle;...uin
05d0: 74 20 20 44 61 74 61 52 65 70 72 65 73 65 6e 74 t DataRepresent
05e0: 61 74 69 6f 6e 3b 0d 0a 09 76 6f 69 64 2a 20 42 ation;...void* B
05f0: 75 66 66 65 72 3b 0d 0a 09 75 69 6e 74 20 20 42 uffer;...uint B
0600: 75 66 66 65 72 4c 65 6e 67 74 68 3b 0d 0a 09 75 ufferLength;...u
0610: 69 6e 74 20 20 50 72 6f 63 4e 75 6d 3b 0d 0a 09 int ProcNum;...
0620: 50 52 50 43 5f 53 59 4e 54 41 58 5f 49 44 45 4e PRPC_SYNTAX_IDEN
0630: 54 49 46 49 45 52 20 54 72 61 6e 73 66 65 72 53 TIFIER TransferS
0640: 79 6e 74 61 78 3b 0d 0a 09 76 6f 69 64 2a 20 52 yntax;...void* R
0650: 70 63 49 6e 74 65 72 66 61 63 65 49 6e 66 6f 72 pcInterfaceInfor
0660: 6d 61 74 69 6f 6e 3b 0d 0a 09 76 6f 69 64 2a 20 mation;...void*
0670: 52 65 73 65 72 76 65 64 46 6f 72 52 75 6e 74 69 ReservedForRunti
0680: 6d 65 3b 0d 0a 09 76 6f 69 64 2a 20 4d 61 6e 61 me;...void* Mana
0690: 67 65 72 45 70 76 3b 0d 0a 09 76 6f 69 64 2a 20 gerEpv;...void*
06a0: 49 6d 70 6f 72 74 43 6f 6e 74 65 78 74 3b 0d 0a ImportContext;..
06b0: 09 75 69 6e 74 20 20 52 70 63 46 6c 61 67 73 3b .uint RpcFlags;
06c0: 0d 0a 7d 0d 0a 61 6c 69 61 73 20 52 50 43 5f 4d ..}..alias RPC_M
06d0: 45 53 53 41 47 45 2a 20 50 52 50 43 5f 4d 45 53 ESSAGE* PRPC_MES
06e0: 53 41 47 45 3b 0d 0a 0d 0a 65 78 74 65 72 6e 20 SAGE;....extern
06f0: 28 57 69 6e 64 6f 77 73 29 20 7b 0d 0a 61 6c 69 (Windows) {..ali
0700: 61 73 20 76 6f 69 64 20 66 75 6e 63 74 69 6f 6e as void function
0710: 20 28 50 52 50 43 5f 4d 45 53 53 41 47 45 20 4d (PRPC_MESSAGE M
0720: 65 73 73 61 67 65 29 20 52 50 43 5f 44 49 53 50 essage) RPC_DISP
0730: 41 54 43 48 5f 46 55 4e 43 54 49 4f 4e 3b 0d 0a ATCH_FUNCTION;..
0740: 7d 0d 0a 0d 0a 73 74 72 75 63 74 20 52 50 43 5f }....struct RPC_
0750: 44 49 53 50 41 54 43 48 5f 54 41 42 4c 45 20 7b DISPATCH_TABLE {
0760: 0d 0a 09 75 69 6e 74 20 44 69 73 70 61 74 63 68 ...uint Dispatch
0770: 54 61 62 6c 65 43 6f 75 6e 74 3b 0d 0a 09 52 50 TableCount;...RP
0780: 43 5f 44 49 53 50 41 54 43 48 5f 46 55 4e 43 54 C_DISPATCH_FUNCT
0790: 49 4f 4e 2a 20 44 69 73 70 61 74 63 68 54 61 62 ION* DispatchTab
07a0: 6c 65 3b 0d 0a 09 69 6e 74 20 20 52 65 73 65 72 le;...int Reser
07b0: 76 65 64 3b 0d 0a 7d 0d 0a 61 6c 69 61 73 20 52 ved;..}..alias R
07c0: 50 43 5f 44 49 53 50 41 54 43 48 5f 54 41 42 4c PC_DISPATCH_TABL
07d0: 45 2a 20 50 52 50 43 5f 44 49 53 50 41 54 43 48 E* PRPC_DISPATCH
07e0: 5f 54 41 42 4c 45 3b 0d 0a 0d 0a 73 74 72 75 63 _TABLE;....struc
07f0: 74 20 52 50 43 5f 50 52 4f 54 53 45 51 5f 45 4e t RPC_PROTSEQ_EN
0800: 44 50 4f 49 4e 54 20 7b 0d 0a 09 75 62 79 74 65 DPOINT {...ubyte
0810: 2a 20 52 70 63 50 72 6f 74 6f 63 6f 6c 53 65 71 * RpcProtocolSeq
0820: 75 65 6e 63 65 3b 0d 0a 09 75 62 79 74 65 2a 20 uence;...ubyte*
0830: 45 6e 64 70 6f 69 6e 74 3b 0d 0a 7d 0d 0a 61 6c Endpoint;..}..al
0840: 69 61 73 20 52 50 43 5f 50 52 4f 54 53 45 51 5f ias RPC_PROTSEQ_
0850: 45 4e 44 50 4f 49 4e 54 2a 20 50 52 50 43 5f 50 ENDPOINT* PRPC_P
0860: 52 4f 54 53 45 51 5f 45 4e 44 50 4f 49 4e 54 3b ROTSEQ_ENDPOINT;
0870: 0d 0a 0d 0a 73 74 72 75 63 74 20 52 50 43 5f 53 ....struct RPC_S
0880: 45 52 56 45 52 5f 49 4e 54 45 52 46 41 43 45 20 ERVER_INTERFACE
0890: 7b 0d 0a 09 75 69 6e 74 20 20 20 20 20 20 20 20 {...uint
08a0: 20 20 20 20 20 20 20 20 20 20 4c 65 6e 67 74 68 Length
08b0: 3b 0d 0a 09 52 50 43 5f 53 59 4e 54 41 58 5f 49 ;...RPC_SYNTAX_I
08c0: 44 45 4e 54 49 46 49 45 52 20 49 6e 74 65 72 66 DENTIFIER Interf
08d0: 61 63 65 49 64 3b 0d 0a 09 52 50 43 5f 53 59 4e aceId;...RPC_SYN
08e0: 54 41 58 5f 49 44 45 4e 54 49 46 49 45 52 20 54 TAX_IDENTIFIER T
08f0: 72 61 6e 73 66 65 72 53 79 6e 74 61 78 3b 0d 0a ransferSyntax;..
0900: 09 50 52 50 43 5f 44 49 53 50 41 54 43 48 5f 54 .PRPC_DISPATCH_T
0910: 41 42 4c 45 20 20 20 44 69 73 70 61 74 63 68 54 ABLE DispatchT
0920: 61 62 6c 65 3b 0d 0a 09 75 69 6e 74 20 20 20 20 able;...uint
0930: 20 20 20 20 20 20 20 20 20 20 20 20 20 20 52 70 Rp
0940: 63 50 72 6f 74 73 65 71 45 6e 64 70 6f 69 6e 74 cProtseqEndpoint
0950: 43 6f 75 6e 74 3b 0d 0a 09 50 52 50 43 5f 50 52 Count;...PRPC_PR
0960: 4f 54 53 45 51 5f 45 4e 44 50 4f 49 4e 54 20 52 OTSEQ_ENDPOINT R
0970: 70 63 50 72 6f 74 73 65 71 45 6e 64 70 6f 69 6e pcProtseqEndpoin
0980: 74 3b 0d 0a 09 76 6f 69 64 2a 20 20 20 20 20 20 t;...void*
0990: 20 20 20 20 20 20 20 20 20 20 20 44 65 66 61 75 Defau
09a0: 6c 74 4d 61 6e 61 67 65 72 45 70 76 3b 0d 0a 09 ltManagerEpv;...
09b0: 63 6f 6e 73 74 28 76 6f 69 64 29 2a 20 20 20 20 const(void)*
09c0: 20 20 20 20 20 20 49 6e 74 65 72 70 72 65 74 65 Interprete
09d0: 72 49 6e 66 6f 3b 0d 0a 7d 0d 0a 61 6c 69 61 73 rInfo;..}..alias
09e0: 20 52 50 43 5f 53 45 52 56 45 52 5f 49 4e 54 45 RPC_SERVER_INTE
09f0: 52 46 41 43 45 2a 20 50 52 50 43 5f 53 45 52 56 RFACE* PRPC_SERV
0a00: 45 52 5f 49 4e 54 45 52 46 41 43 45 3b 0d 0a 0d ER_INTERFACE;...
0a10: 0a 73 74 72 75 63 74 20 52 50 43 5f 43 4c 49 45 .struct RPC_CLIE
0a20: 4e 54 5f 49 4e 54 45 52 46 41 43 45 20 7b 0d 0a NT_INTERFACE {..
0a30: 09 75 69 6e 74 20 20 20 20 20 20 20 20 20 20 20 .uint
0a40: 20 20 20 20 20 20 20 4c 65 6e 67 74 68 3b 0d 0a Length;..
0a50: 09 52 50 43 5f 53 59 4e 54 41 58 5f 49 44 45 4e .RPC_SYNTAX_IDEN
0a60: 54 49 46 49 45 52 20 49 6e 74 65 72 66 61 63 65 TIFIER Interface
0a70: 49 64 3b 0d 0a 09 52 50 43 5f 53 59 4e 54 41 58 Id;...RPC_SYNTAX
0a80: 5f 49 44 45 4e 54 49 46 49 45 52 20 54 72 61 6e _IDENTIFIER Tran
0a90: 73 66 65 72 53 79 6e 74 61 78 3b 0d 0a 09 50 52 sferSyntax;...PR
0aa0: 50 43 5f 44 49 53 50 41 54 43 48 5f 54 41 42 4c PC_DISPATCH_TABL
0ab0: 45 20 20 20 44 69 73 70 61 74 63 68 54 61 62 6c E DispatchTabl
0ac0: 65 3b 0d 0a 09 75 69 6e 74 20 20 20 20 20 20 20 e;...uint
0ad0: 20 20 20 20 20 20 20 20 20 20 20 52 70 63 50 72 RpcPr
0ae0: 6f 74 73 65 71 45 6e 64 70 6f 69 6e 74 43 6f 75 otseqEndpointCou
0af0: 6e 74 3b 0d 0a 09 50 52 50 43 5f 50 52 4f 54 53 nt;...PRPC_PROTS
0b00: 45 51 5f 45 4e 44 50 4f 49 4e 54 20 52 70 63 50 EQ_ENDPOINT RpcP
0b10: 72 6f 74 73 65 71 45 6e 64 70 6f 69 6e 74 3b 0d rotseqEndpoint;.
0b20: 0a 09 75 69 6e 74 20 20 20 20 20 20 20 20 20 20 ..uint
0b30: 20 20 20 20 20 20 20 20 52 65 73 65 72 76 65 64 Reserved
0b40: 3b 0d 0a 09 63 6f 6e 73 74 28 76 6f 69 64 29 2a ;...const(void)*
0b50: 20 20 20 20 20 20 20 20 20 20 49 6e 74 65 72 70 Interp
0b60: 72 65 74 65 72 49 6e 66 6f 3b 0d 0a 7d 0d 0a 61 reterInfo;..}..a
0b70: 6c 69 61 73 20 52 50 43 5f 43 4c 49 45 4e 54 5f lias RPC_CLIENT_
0b80: 49 4e 54 45 52 46 41 43 45 2a 20 50 52 50 43 5f INTERFACE* PRPC_
0b90: 43 4c 49 45 4e 54 5f 49 4e 54 45 52 46 41 43 45 CLIENT_INTERFACE
0ba0: 3b 0d 0a 0d 0a 61 6c 69 61 73 20 54 79 70 65 44 ;....alias TypeD
0bb0: 65 66 21 28 76 6f 69 64 2a 29 20 49 5f 52 50 43 ef!(void*) I_RPC
0bc0: 5f 4d 55 54 45 58 3b 0d 0a 0d 0a 73 74 72 75 63 _MUTEX;....struc
0bd0: 74 20 52 50 43 5f 54 52 41 4e 53 46 45 52 5f 53 t RPC_TRANSFER_S
0be0: 59 4e 54 41 58 20 7b 0d 0a 09 47 55 49 44 20 20 YNTAX {...GUID
0bf0: 20 55 75 69 64 3b 0d 0a 09 75 73 68 6f 72 74 20 Uuid;...ushort
0c00: 56 65 72 73 4d 61 6a 6f 72 3b 0d 0a 09 75 73 68 VersMajor;...ush
0c10: 6f 72 74 20 56 65 72 73 4d 69 6e 6f 72 3b 0d 0a ort VersMinor;..
0c20: 7d 0d 0a 61 6c 69 61 73 20 52 50 43 5f 53 54 41 }..alias RPC_STA
0c30: 54 55 53 20 66 75 6e 63 74 69 6f 6e 28 76 6f 69 TUS function(voi
0c40: 64 2a 2c 20 76 6f 69 64 2a 2c 20 76 6f 69 64 2a d*, void*, void*
0c50: 29 20 52 50 43 5f 42 4c 4f 43 4b 49 4e 47 5f 46 ) RPC_BLOCKING_F
0c60: 4e 3b 0d 0a 0d 0a 65 78 74 65 72 6e 20 28 57 69 N;....extern (Wi
0c70: 6e 64 6f 77 73 29 20 7b 0d 0a 09 61 6c 69 61 73 ndows) {...alias
0c80: 20 76 6f 69 64 20 66 75 6e 63 74 69 6f 6e 28 76 void function(v
0c90: 6f 69 64 2a 29 20 50 52 50 43 5f 52 55 4e 44 4f oid*) PRPC_RUNDO
0ca0: 57 4e 3b 0d 0a 09 0d 0a 09 69 6e 74 20 20 20 20 WN;......int
0cb0: 49 5f 52 70 63 47 65 74 42 75 66 66 65 72 28 52 I_RpcGetBuffer(R
0cc0: 50 43 5f 4d 45 53 53 41 47 45 2a 29 3b 0d 0a 09 PC_MESSAGE*);...
0cd0: 69 6e 74 20 20 20 20 49 5f 52 70 63 53 65 6e 64 int I_RpcSend
0ce0: 52 65 63 65 69 76 65 28 52 50 43 5f 4d 45 53 53 Receive(RPC_MESS
0cf0: 41 47 45 2a 29 3b 0d 0a 09 69 6e 74 20 20 20 20 AGE*);...int
0d00: 49 5f 52 70 63 53 65 6e 64 28 52 50 43 5f 4d 45 I_RpcSend(RPC_ME
0d10: 53 53 41 47 45 2a 29 3b 0d 0a 09 69 6e 74 20 20 SSAGE*);...int
0d20: 20 20 49 5f 52 70 63 46 72 65 65 42 75 66 66 65 I_RpcFreeBuffe
0d30: 72 28 52 50 43 5f 4d 45 53 53 41 47 45 2a 29 3b r(RPC_MESSAGE*);
0d40: 0d 0a 09 76 6f 69 64 20 20 20 49 5f 52 70 63 52 ...void I_RpcR
0d50: 65 71 75 65 73 74 4d 75 74 65 78 28 49 5f 52 50 equestMutex(I_RP
0d60: 43 5f 4d 55 54 45 58 2a 29 3b 0d 0a 09 76 6f 69 C_MUTEX*);...voi
0d70: 64 20 20 20 49 5f 52 70 63 43 6c 65 61 72 4d 75 d I_RpcClearMu
0d80: 74 65 78 28 49 5f 52 50 43 5f 4d 55 54 45 58 29 tex(I_RPC_MUTEX)
0d90: 3b 0d 0a 09 76 6f 69 64 20 20 20 49 5f 52 70 63 ;...void I_Rpc
0da0: 44 65 6c 65 74 65 4d 75 74 65 78 28 49 5f 52 50 DeleteMutex(I_RP
0db0: 43 5f 4d 55 54 45 58 29 3b 0d 0a 09 76 6f 69 64 C_MUTEX);...void
0dc0: 2a 20 20 49 5f 52 70 63 41 6c 6c 6f 63 61 74 65 * I_RpcAllocate
0dd0: 28 75 69 6e 74 29 3b 0d 0a 09 76 6f 69 64 20 20 (uint);...void
0de0: 20 49 5f 52 70 63 46 72 65 65 28 76 6f 69 64 2a I_RpcFree(void*
0df0: 29 3b 0d 0a 09 76 6f 69 64 20 20 20 49 5f 52 70 );...void I_Rp
0e00: 63 50 61 75 73 65 45 78 65 63 75 74 69 6f 6e 28 cPauseExecution(
0e10: 75 69 6e 74 29 3b 0d 0a 09 69 6e 74 20 20 20 20 uint);...int
0e20: 49 5f 52 70 63 4d 6f 6e 69 74 6f 72 41 73 73 6f I_RpcMonitorAsso
0e30: 63 69 61 74 69 6f 6e 28 48 41 4e 44 4c 45 2c 20 ciation(HANDLE,
0e40: 50 52 50 43 5f 52 55 4e 44 4f 57 4e 2c 20 76 6f PRPC_RUNDOWN, vo
0e50: 69 64 2a 29 3b 0d 0a 09 69 6e 74 20 20 20 20 49 id*);...int I
0e60: 5f 52 70 63 53 74 6f 70 4d 6f 6e 69 74 6f 72 41 _RpcStopMonitorA
0e70: 73 73 6f 63 69 61 74 69 6f 6e 28 48 41 4e 44 4c ssociation(HANDL
0e80: 45 29 3b 0d 0a 09 48 41 4e 44 4c 45 20 49 5f 52 E);...HANDLE I_R
0e90: 70 63 47 65 74 43 75 72 72 65 6e 74 43 61 6c 6c pcGetCurrentCall
0ea0: 48 61 6e 64 6c 65 28 29 3b 0d 0a 09 69 6e 74 20 Handle();...int
0eb0: 20 20 20 49 5f 52 70 63 47 65 74 41 73 73 6f 63 I_RpcGetAssoc
0ec0: 69 61 74 69 6f 6e 43 6f 6e 74 65 78 74 28 76 6f iationContext(vo
0ed0: 69 64 2a 2a 29 3b 0d 0a 09 69 6e 74 20 20 20 20 id**);...int
0ee0: 49 5f 52 70 63 53 65 74 41 73 73 6f 63 69 61 74 I_RpcSetAssociat
0ef0: 69 6f 6e 43 6f 6e 74 65 78 74 28 76 6f 69 64 2a ionContext(void*
0f00: 29 3b 0d 0a 09 69 6e 74 20 20 20 20 49 5f 52 70 );...int I_Rp
0f10: 63 4e 73 42 69 6e 64 69 6e 67 53 65 74 45 6e 74 cNsBindingSetEnt
0f20: 72 79 4e 61 6d 65 28 48 41 4e 44 4c 45 2c 20 75 ryName(HANDLE, u
0f30: 69 6e 74 2c 20 77 63 68 61 72 2a 29 3b 0d 0a 09 int, wchar*);...
0f40: 69 6e 74 20 20 20 20 49 5f 52 70 63 42 69 6e 64 int I_RpcBind
0f50: 69 6e 67 49 6e 71 44 79 6e 61 6d 69 63 45 6e 64 ingInqDynamicEnd
0f60: 70 6f 69 6e 74 28 48 41 4e 44 4c 45 2c 20 77 63 point(HANDLE, wc
0f70: 68 61 72 2a 2a 29 3b 0d 0a 09 69 6e 74 20 20 20 har**);...int
0f80: 20 49 5f 52 70 63 42 69 6e 64 69 6e 67 49 6e 71 I_RpcBindingInq
0f90: 54 72 61 6e 73 70 6f 72 74 54 79 70 65 28 48 41 TransportType(HA
0fa0: 4e 44 4c 45 2c 20 75 69 6e 74 2a 29 3b 0d 0a 09 NDLE, uint*);...
0fb0: 69 6e 74 20 20 20 20 49 5f 52 70 63 49 66 49 6e int I_RpcIfIn
0fc0: 71 54 72 61 6e 73 66 65 72 53 79 6e 74 61 78 65 qTransferSyntaxe
0fd0: 73 28 48 41 4e 44 4c 45 2c 20 52 50 43 5f 54 52 s(HANDLE, RPC_TR
0fe0: 41 4e 53 46 45 52 5f 53 59 4e 54 41 58 2a 2c 20 ANSFER_SYNTAX*,
0ff0: 75 69 6e 74 2c 0d 0a 09 20 20 20 20 20 20 20 20 uint,...
1000: 20 75 69 6e 74 2a 29 3b 0d 0a 09 69 6e 74 20 20 uint*);...int
1010: 20 20 49 5f 55 75 69 64 43 72 65 61 74 65 28 47 I_UuidCreate(G
1020: 55 49 44 2a 29 3b 0d 0a 09 69 6e 74 20 20 20 20 UID*);...int
1030: 49 5f 52 70 63 42 69 6e 64 69 6e 67 43 6f 70 79 I_RpcBindingCopy
1040: 28 48 41 4e 44 4c 45 2c 20 48 41 4e 44 4c 45 2a (HANDLE, HANDLE*
1050: 29 3b 0d 0a 09 69 6e 74 20 20 20 20 49 5f 52 70 );...int I_Rp
1060: 63 42 69 6e 64 69 6e 67 49 73 43 6c 69 65 6e 74 cBindingIsClient
1070: 4c 6f 63 61 6c 28 48 41 4e 44 4c 45 2c 20 75 69 Local(HANDLE, ui
1080: 6e 74 2a 29 3b 0d 0a 09 76 6f 69 64 20 20 20 49 nt*);...void I
1090: 5f 52 70 63 53 73 44 6f 6e 74 53 65 72 69 61 6c _RpcSsDontSerial
10a0: 69 7a 65 43 6f 6e 74 65 78 74 28 29 3b 0d 0a 09 izeContext();...
10b0: 69 6e 74 20 20 20 20 49 5f 52 70 63 53 65 72 76 int I_RpcServ
10c0: 65 72 52 65 67 69 73 74 65 72 46 6f 72 77 61 72 erRegisterForwar
10d0: 64 46 75 6e 63 74 69 6f 6e 28 69 6e 74 20 66 75 dFunction(int fu
10e0: 6e 63 74 69 6f 6e 20 28 47 55 49 44 2a 2c 0d 0a nction (GUID*,..
10f0: 09 20 20 20 20 20 20 20 20 20 52 50 43 5f 56 45 . RPC_VE
1100: 52 53 49 4f 4e 2a 2c 20 47 55 49 44 2a 2c 20 75 RSION*, GUID*, u
1110: 62 79 74 65 2a 2c 20 76 6f 69 64 2a 2a 29 29 3b byte*, void**));
1120: 0d 0a 09 69 6e 74 20 20 20 20 49 5f 52 70 63 43 ...int I_RpcC
1130: 6f 6e 6e 65 63 74 69 6f 6e 49 6e 71 53 6f 63 6b onnectionInqSock
1140: 42 75 66 66 53 69 7a 65 28 75 69 6e 74 2a 2c 20 BuffSize(uint*,
1150: 75 69 6e 74 2a 29 3b 0d 0a 09 69 6e 74 20 20 20 uint*);...int
1160: 20 49 5f 52 70 63 43 6f 6e 6e 65 63 74 69 6f 6e I_RpcConnection
1170: 53 65 74 53 6f 63 6b 42 75 66 66 53 69 7a 65 28 SetSockBuffSize(
1180: 75 69 6e 74 2c 20 75 69 6e 74 29 3b 0d 0a 09 69 uint, uint);...i
1190: 6e 74 20 20 20 20 49 5f 52 70 63 42 69 6e 64 69 nt I_RpcBindi
11a0: 6e 67 53 65 74 41 73 79 6e 63 28 48 41 4e 44 4c ngSetAsync(HANDL
11b0: 45 2c 20 52 50 43 5f 42 4c 4f 43 4b 49 4e 47 5f E, RPC_BLOCKING_
11c0: 46 4e 29 3b 0d 0a 09 69 6e 74 20 20 20 20 49 5f FN);...int I_
11d0: 52 70 63 41 73 79 6e 63 53 65 6e 64 52 65 63 65 RpcAsyncSendRece
11e0: 69 76 65 28 52 50 43 5f 4d 45 53 53 41 47 45 2a ive(RPC_MESSAGE*
11f0: 2c 20 76 6f 69 64 2a 29 3b 0d 0a 09 69 6e 74 20 , void*);...int
1200: 20 20 20 49 5f 52 70 63 47 65 74 54 68 72 65 61 I_RpcGetThrea
1210: 64 57 69 6e 64 6f 77 48 61 6e 64 6c 65 28 76 6f dWindowHandle(vo
1220: 69 64 2a 2a 29 3b 0d 0a 09 69 6e 74 20 20 20 20 id**);...int
1230: 49 5f 52 70 63 53 65 72 76 65 72 54 68 72 65 61 I_RpcServerThrea
1240: 64 50 61 75 73 65 4c 69 73 74 65 6e 69 6e 67 28 dPauseListening(
1250: 29 3b 0d 0a 09 69 6e 74 20 20 20 20 49 5f 52 70 );...int I_Rp
1260: 63 53 65 72 76 65 72 54 68 72 65 61 64 43 6f 6e cServerThreadCon
1270: 74 69 6e 75 65 4c 69 73 74 65 6e 69 6e 67 28 29 tinueListening()
1280: 3b 0d 0a 09 69 6e 74 20 20 20 20 49 5f 52 70 63 ;...int I_Rpc
1290: 53 65 72 76 65 72 55 6e 72 65 67 69 73 74 65 72 ServerUnregister
12a0: 45 6e 64 70 6f 69 6e 74 41 28 75 62 79 74 65 2a EndpointA(ubyte*
12b0: 2c 20 75 62 79 74 65 2a 29 3b 0d 0a 09 69 6e 74 , ubyte*);...int
12c0: 20 20 20 20 49 5f 52 70 63 53 65 72 76 65 72 55 I_RpcServerU
12d0: 6e 72 65 67 69 73 74 65 72 45 6e 64 70 6f 69 6e nregisterEndpoin
12e0: 74 57 28 75 73 68 6f 72 74 2a 2c 20 75 73 68 6f tW(ushort*, usho
12f0: 72 74 2a 29 3b 0d 0a 7d 0d 0a 0d 0a 76 65 72 73 rt*);..}....vers
1300: 69 6f 6e 28 55 6e 69 63 6f 64 65 29 20 7b 0d 0a ion(Unicode) {..
1310: 09 61 6c 69 61 73 20 49 5f 52 70 63 53 65 72 76 .alias I_RpcServ
1320: 65 72 55 6e 72 65 67 69 73 74 65 72 45 6e 64 70 erUnregisterEndp
1330: 6f 69 6e 74 57 20 49 5f 52 70 63 53 65 72 76 65 ointW I_RpcServe
1340: 72 55 6e 72 65 67 69 73 74 65 72 45 6e 64 70 6f rUnregisterEndpo
1350: 69 6e 74 3b 0d 0a 7d 20 65 6c 73 65 20 7b 0d 0a int;..} else {..
1360: 09 61 6c 69 61 73 20 49 5f 52 70 63 53 65 72 76 .alias I_RpcServ
1370: 65 72 55 6e 72 65 67 69 73 74 65 72 45 6e 64 70 erUnregisterEndp
1380: 6f 69 6e 74 41 20 49 5f 52 70 63 53 65 72 76 65 ointA I_RpcServe
1390: 72 55 6e 72 65 67 69 73 74 65 72 45 6e 64 70 6f rUnregisterEndpo
13a0: 69 6e 74 3b 0d 0a 7d 0d 0a int;..}..