Added /g debug format to dump GUIDs.
[wine/multimedia.git] / include / ntdef.h
blob61d5b58eeb49ceb1b97fcde00cd40488f905e57a
1 /*
2 * Copyright (C) 1999 Juergen Schmied
4 * This library is free software; you can redistribute it and/or
5 * modify it under the terms of the GNU Lesser General Public
6 * License as published by the Free Software Foundation; either
7 * version 2.1 of the License, or (at your option) any later version.
9 * This library is distributed in the hope that it will be useful,
10 * but WITHOUT ANY WARRANTY; without even the implied warranty of
11 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
12 * Lesser General Public License for more details.
14 * You should have received a copy of the GNU Lesser General Public
15 * License along with this library; if not, write to the Free Software
16 * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
19 #ifndef __WINE_NTDEF_H
20 #define __WINE_NTDEF_H
22 #include "basetsd.h"
23 #include "windef.h"
25 #ifdef __cplusplus
26 extern "C" {
27 #endif
29 #define NTAPI __stdcall
31 #ifndef IN
32 #define IN
33 #endif
35 #ifndef OUT
36 #define OUT
37 #endif
39 #ifndef OPTIONAL
40 #define OPTIONAL
41 #endif
43 #ifndef VOID
44 #define VOID void
45 #endif
47 typedef LONG NTSTATUS;
48 typedef NTSTATUS *PNTSTATUS;
50 typedef short CSHORT;
51 typedef CSHORT *PCSHORT;
54 /* NT lowlevel Strings (handled by Rtl* functions in NTDLL)
55 * If they are zero terminated, Length does not include the terminating 0.
58 typedef struct _STRING {
59 USHORT Length;
60 USHORT MaximumLength;
61 PSTR Buffer;
62 } STRING,*PSTRING,ANSI_STRING,*PANSI_STRING;
64 typedef struct _CSTRING {
65 USHORT Length;
66 USHORT MaximumLength;
67 PCSTR Buffer;
68 } CSTRING,*PCSTRING;
70 typedef struct _UNICODE_STRING {
71 USHORT Length; /* bytes */
72 USHORT MaximumLength; /* bytes */
73 PWSTR Buffer;
74 } UNICODE_STRING,*PUNICODE_STRING;
77 Objects
80 #define OBJ_INHERIT 0x00000002L
81 #define OBJ_PERMANENT 0x00000010L
82 #define OBJ_EXCLUSIVE 0x00000020L
83 #define OBJ_CASE_INSENSITIVE 0x00000040L
84 #define OBJ_OPENIF 0x00000080L
85 #define OBJ_OPENLINK 0x00000100L
86 #define OBJ_KERNEL_HANDLE 0x00000200L
87 #define OBJ_VALID_ATTRIBUTES 0x000003F2L
89 typedef struct _OBJECT_ATTRIBUTES
90 { ULONG Length;
91 HANDLE RootDirectory;
92 PUNICODE_STRING ObjectName;
93 ULONG Attributes;
94 PVOID SecurityDescriptor; /* type SECURITY_DESCRIPTOR */
95 PVOID SecurityQualityOfService; /* type SECURITY_QUALITY_OF_SERVICE */
96 } OBJECT_ATTRIBUTES;
98 typedef OBJECT_ATTRIBUTES *POBJECT_ATTRIBUTES;
100 #define InitializeObjectAttributes(p,n,a,r,s) \
101 { (p)->Length = sizeof(OBJECT_ATTRIBUTES); \
102 (p)->RootDirectory = r; \
103 (p)->Attributes = a; \
104 (p)->ObjectName = n; \
105 (p)->SecurityDescriptor = s; \
106 (p)->SecurityQualityOfService = NULL; \
110 #ifdef __cplusplus
112 #endif
114 #endif