include: Add reparse point definitions and structures

André Hentschel nerv at dawncrow.de
Sun Jan 1 10:15:05 CST 2012


---
 include/winnt.h |   65 +++++++++++++++++++++++++++++++++++++++++++++++++++++++
 1 files changed, 65 insertions(+), 0 deletions(-)

diff --git a/include/winnt.h b/include/winnt.h
index fc471b8..9b8583e 100644
--- a/include/winnt.h
+++ b/include/winnt.h
@@ -5180,6 +5180,71 @@ typedef enum _ACTIVATION_CONTEXT_INFO_CLASS {
 #define ACTIVATION_CONTEXT_SECTION_GLOBAL_OBJECT_RENAME_TABLE    8
 #define ACTIVATION_CONTEXT_SECTION_CLR_SURROGATES                9
 
+#define REPARSE_DATA_BUFFER_HEADER_SIZE      FIELD_OFFSET(REPARSE_DATA_BUFFER, GenericReparseBuffer)
+#define REPARSE_GUID_DATA_BUFFER_HEADER_SIZE FIELD_OFFSET(REPARSE_GUID_DATA_BUFFER, GenericReparseBuffer)
+#define MAXIMUM_REPARSE_DATA_BUFFER_SIZE     0x4000
+
+#define IO_REPARSE_TAG_RESERVED_ZERO         0
+#define IO_REPARSE_TAG_RESERVED_ONE          1
+#define IO_REPARSE_TAG_RESERVED_RANGE        IO_REPARSE_TAG_RESERVED_ONE
+#define IO_REPARSE_TAG_VALID_VALUES          0xE000FFFF
+#define IO_REPARSE_TAG_SYMBOLIC_LINK         IO_REPARSE_TAG_RESERVED_ZERO
+#define IO_REPARSE_TAG_DFS                   0x8000000A
+#define IO_REPARSE_TAG_DFSR                  0x80000012
+#define IO_REPARSE_TAG_HSM                   0xC0000004
+#define IO_REPARSE_TAG_HSM2                  0x80000006
+#define IO_REPARSE_TAG_MOUNT_POINT           0xA0000003
+#define IO_REPARSE_TAG_SIS                   0x80000007
+#define IO_REPARSE_TAG_SYMLINK               0xA000000C
+
+#define IsReparseTagMicrosoft(x)             ((x)&0x80000000)
+#define IsReparseTagHighLatency(x)           ((x)&0x40000000)
+#define IsReparseTagNameSurrogate(x)         ((x)&0x20000000)
+#define IsReparseTagValid(x)                 (!((x)&~IO_REPARSE_TAG_VALID_VALUES)&&((x)>IO_REPARSE_TAG_RESERVED_RANGE))
+
+typedef struct _REPARSE_DATA_BUFFER
+{
+    DWORD ReparseTag;
+    WORD  ReparseDataLength;
+    WORD  Reserved;
+    union {
+        struct {
+            WORD  SubstituteNameOffset;
+            WORD  SubstituteNameLength;
+            WORD  PrintNameOffset;
+            WORD  PrintNameLength;
+            WCHAR PathBuffer[1];
+        } SymbolicLinkReparseBuffer;
+        struct {
+            WORD  SubstituteNameOffset;
+            WORD  SubstituteNameLength;
+            WORD  PrintNameOffset;
+            WORD  PrintNameLength;
+            WCHAR PathBuffer[1];
+        } MountPointReparseBuffer;
+        struct {
+            BYTE  DataBuffer[1];
+        } GenericReparseBuffer;
+    } DUMMYUNIONNAME;
+} REPARSE_DATA_BUFFER, *PREPARSE_DATA_BUFFER;
+
+typedef struct _REPARSE_GUID_DATA_BUFFER
+{
+    DWORD ReparseTag;
+    WORD  ReparseDataLength;
+    WORD  Reserved;
+    GUID  ReparseGuid;
+    struct {
+        BYTE DataBuffer[1];
+    } GenericReparseBuffer;
+} REPARSE_GUID_DATA_BUFFER, *PREPARSE_GUID_DATA_BUFFER;
+
+typedef struct _REPARSE_POINT_INFORMATION
+{
+    WORD ReparseDataLength;
+    WORD UnparsedNameLength;
+} REPARSE_POINT_INFORMATION, *PREPARSE_POINT_INFORMATION;
+
 typedef enum _JOBOBJECTINFOCLASS
 {
     JobObjectBasicAccountingInformation = 1,
-- 

Best Regards, André Hentschel
-------------- next part --------------
An embedded and charset-unspecified text was scrubbed...
Name: Nachrichtenteil als Anhang
URL: <http://www.winehq.org/pipermail/wine-patches/attachments/20120101/b97d42c7/attachment.ksh>


More information about the wine-patches mailing list