aboutsummaryrefslogtreecommitdiff
path: root/src/internal/syscall/windows
diff options
context:
space:
mode:
Diffstat (limited to 'src/internal/syscall/windows')
-rw-r--r--src/internal/syscall/windows/at_windows.go6
-rw-r--r--src/internal/syscall/windows/types_windows.go8
2 files changed, 7 insertions, 7 deletions
diff --git a/src/internal/syscall/windows/at_windows.go b/src/internal/syscall/windows/at_windows.go
index f1360872f5..a5601493d8 100644
--- a/src/internal/syscall/windows/at_windows.go
+++ b/src/internal/syscall/windows/at_windows.go
@@ -355,7 +355,7 @@ func deleteatFallback(h syscall.Handle) error {
h,
FileDispositionInfo,
unsafe.Pointer(&FILE_DISPOSITION_INFO{
- DeleteFile: true,
+ DeleteFile: 1,
}),
uint32(unsafe.Sizeof(FILE_DISPOSITION_INFO{})),
)
@@ -416,7 +416,7 @@ func Renameat(olddirfd syscall.Handle, oldpath string, newdirfd syscall.Handle,
//
// Try again.
renameInfo := FILE_RENAME_INFORMATION{
- ReplaceIfExists: true,
+ ReplaceIfExists: 1,
RootDirectory: newdirfd,
}
copy(renameInfo.FileName[:], p16)
@@ -602,7 +602,7 @@ func symlinkat(oldname string, newdirfd syscall.Handle, newname string, flags Sy
h,
&IO_STATUS_BLOCK{},
unsafe.Pointer(&FILE_DISPOSITION_INFORMATION{
- DeleteFile: true,
+ DeleteFile: 1,
}),
uint32(unsafe.Sizeof(FILE_DISPOSITION_INFORMATION{})),
FileDispositionInformation,
diff --git a/src/internal/syscall/windows/types_windows.go b/src/internal/syscall/windows/types_windows.go
index 21aeb8faf9..a3d92b2b35 100644
--- a/src/internal/syscall/windows/types_windows.go
+++ b/src/internal/syscall/windows/types_windows.go
@@ -219,12 +219,12 @@ const (
// https://learn.microsoft.com/en-us/windows/win32/api/winbase/ns-winbase-file_disposition_info
type FILE_DISPOSITION_INFO struct {
- DeleteFile bool
+ DeleteFile byte
}
// https://learn.microsoft.com/en-us/windows-hardware/drivers/ddi/ntddk/ns-ntddk-_file_disposition_information
type FILE_DISPOSITION_INFORMATION struct {
- DeleteFile bool
+ DeleteFile byte
}
// https://learn.microsoft.com/en-us/windows-hardware/drivers/ddi/ntddk/ns-ntddk-_file_disposition_information_ex
@@ -250,7 +250,7 @@ const (
// https://learn.microsoft.com/en-us/windows-hardware/drivers/ddi/ntifs/ns-ntifs-_file_rename_information
type FILE_RENAME_INFORMATION struct {
- ReplaceIfExists bool
+ ReplaceIfExists byte
RootDirectory syscall.Handle
FileNameLength uint32
FileName [syscall.MAX_PATH]uint16
@@ -266,7 +266,7 @@ type FILE_RENAME_INFORMATION_EX struct {
// https://learn.microsoft.com/en-us/windows-hardware/drivers/ddi/ntifs/ns-ntifs-_file_link_information
type FILE_LINK_INFORMATION struct {
- ReplaceIfExists bool
+ ReplaceIfExists byte
RootDirectory syscall.Handle
FileNameLength uint32
FileName [syscall.MAX_PATH]uint16