Skip to content

Commit 5f15af1

Browse files
author
Bryan C. Mills
committed
syscall: comment on fields omitted from the win32finddata1 struct
Updates #42637 Change-Id: I4c7d38034b60c2c04efdeb530a97d96deddfd6fe Reviewed-on: https://go-review.googlesource.com/c/go/+/284152 Trust: Bryan C. Mills <[email protected]> Trust: Jason A. Donenfeld <[email protected]> Trust: Alex Brainman <[email protected]> Run-TryBot: Bryan C. Mills <[email protected]> TryBot-Result: Go Bot <[email protected]> Reviewed-by: Jason A. Donenfeld <[email protected]> Reviewed-by: Alex Brainman <[email protected]>
1 parent 9a7fe19 commit 5f15af1

File tree

1 file changed

+8
-0
lines changed

1 file changed

+8
-0
lines changed

src/syscall/types_windows.go

+8
Original file line numberDiff line numberDiff line change
@@ -398,6 +398,14 @@ type win32finddata1 struct {
398398
Reserved1 uint32
399399
FileName [MAX_PATH]uint16
400400
AlternateFileName [14]uint16
401+
402+
// The Microsoft documentation for this struct¹ describes three additional
403+
// fields: dwFileType, dwCreatorType, and wFinderFlags. However, those fields
404+
// are empirically only present in the macOS port of the Win32 API,² and thus
405+
// not needed for binaries built for Windows.
406+
//
407+
// ¹ https://docs.microsoft.com/en-us/windows/win32/api/minwinbase/ns-minwinbase-win32_find_dataw
408+
// ² https://golang.org/issue/42637#issuecomment-760715755
401409
}
402410

403411
func copyFindData(dst *Win32finddata, src *win32finddata1) {

0 commit comments

Comments
 (0)