Skip to content

Commit d008cdc

Browse files
Pawel Knapbradfitz
Pawel Knap
authored andcommitted
go.sys/windows: Add missing FILE_NOTIFY_CHANGE_SECURITY filter
According to ReadDirectoryChangesW documentation, this parameter is perfectly valid and its absence in current enumeration makes it incomplete. Internal flags like FILE_NOTIFY_CHANGE_EA were not added. Change-Id: I9d4182dcfa67e67289c0cc35155a64bf5e5152db Reviewed-on: https://go-review.googlesource.com/6560 Reviewed-by: Alex Brainman <[email protected]>
1 parent ddd1cda commit d008cdc

File tree

1 file changed

+9
-8
lines changed

1 file changed

+9
-8
lines changed

windows/ztypes_windows.go

+9-8
Original file line numberDiff line numberDiff line change
@@ -195,14 +195,15 @@ const (
195195
)
196196

197197
const (
198-
// do not reorder
199-
FILE_NOTIFY_CHANGE_FILE_NAME = 1 << iota
200-
FILE_NOTIFY_CHANGE_DIR_NAME
201-
FILE_NOTIFY_CHANGE_ATTRIBUTES
202-
FILE_NOTIFY_CHANGE_SIZE
203-
FILE_NOTIFY_CHANGE_LAST_WRITE
204-
FILE_NOTIFY_CHANGE_LAST_ACCESS
205-
FILE_NOTIFY_CHANGE_CREATION
198+
// filters for ReadDirectoryChangesW
199+
FILE_NOTIFY_CHANGE_FILE_NAME = 0x001
200+
FILE_NOTIFY_CHANGE_DIR_NAME = 0x002
201+
FILE_NOTIFY_CHANGE_ATTRIBUTES = 0x004
202+
FILE_NOTIFY_CHANGE_SIZE = 0x008
203+
FILE_NOTIFY_CHANGE_LAST_WRITE = 0x010
204+
FILE_NOTIFY_CHANGE_LAST_ACCESS = 0x020
205+
FILE_NOTIFY_CHANGE_CREATION = 0x040
206+
FILE_NOTIFY_CHANGE_SECURITY = 0x100
206207
)
207208

208209
const (

0 commit comments

Comments
 (0)