Ruby  2.5.0dev(2017-10-22revision60238)
file.h
Go to the documentation of this file.
1 #ifndef RUBY_WIN32_FILE_H
2 #define RUBY_WIN32_FILE_H
3 
4 #define MAX_REPARSE_PATH_LEN 4092
5 
6 enum {
8 };
9 /* License: Ruby's */
10 typedef struct {
11  ULONG ReparseTag;
13  USHORT Reserved;
14  union {
15  struct {
20  ULONG Flags;
21  WCHAR PathBuffer[4];
22  } SymbolicLinkReparseBuffer;
23  struct {
24  USHORT SubstituteNameOffset;
25  USHORT SubstituteNameLength;
26  USHORT PrintNameOffset;
27  USHORT PrintNameLength;
28  WCHAR PathBuffer[4];
29  } MountPointReparseBuffer;
30  };
32 
33 #define rb_w32_reparse_buffer_size(n) \
34  (sizeof(rb_w32_reparse_buffer_t) + \
35  sizeof(WCHAR)*((n)-MINIMUM_REPARSE_BUFFER_PATH_LEN))
36 
37 int rb_w32_read_reparse_point(const WCHAR *path, rb_w32_reparse_buffer_t *rp,
38  size_t bufsize, WCHAR **result, DWORD *len);
39 
40 int lchown(const char *path, int owner, int group);
41 int rb_w32_ulchown(const char *path, int owner, int group);
42 int fchmod(int fd, int mode);
43 #define HAVE_FCHMOD 0
44 
45 UINT rb_w32_filecp(void);
46 WCHAR *rb_w32_home_dir(void);
47 
48 #endif /* RUBY_WIN32_FILE_H */
int rb_w32_read_reparse_point(const WCHAR *path, rb_w32_reparse_buffer_t *rp, size_t bufsize, WCHAR **result, DWORD *len)
Definition: win32.c:5006
int lchown(const char *path, int owner, int group)
Definition: win32.c:4770
int rb_w32_ulchown(const char *path, int owner, int group)
Definition: win32.c:4776
WCHAR * rb_w32_home_dir(void)
Definition: win32.c:540
USHORT SubstituteNameLength
Definition: file.h:17
IUnknown DWORD
Definition: win32ole.c:32
USHORT PrintNameOffset
Definition: file.h:18
USHORT ReparseDataLength
Definition: file.h:12
USHORT PrintNameLength
Definition: file.h:19
register unsigned int len
Definition: zonetab.h:51
UINT rb_w32_filecp(void)
int fchmod(int fd, int mode)
Definition: win32.c:7572
USHORT SubstituteNameOffset
Definition: file.h:16