mirror of
https://gitea.com/Lydanne/buildx.git
synced 2025-07-14 07:27:07 +08:00
vendor: github.com/moby/buildkit v0.21.0-rc1
Signed-off-by: Jonathan A. Sternberg <jonathan.sternberg@docker.com>
This commit is contained in:
13
vendor/golang.org/x/sys/windows/registry/key.go
generated
vendored
13
vendor/golang.org/x/sys/windows/registry/key.go
generated
vendored
@ -164,7 +164,12 @@ loopItems:
|
||||
func CreateKey(k Key, path string, access uint32) (newk Key, openedExisting bool, err error) {
|
||||
var h syscall.Handle
|
||||
var d uint32
|
||||
err = regCreateKeyEx(syscall.Handle(k), syscall.StringToUTF16Ptr(path),
|
||||
var pathPointer *uint16
|
||||
pathPointer, err = syscall.UTF16PtrFromString(path)
|
||||
if err != nil {
|
||||
return 0, false, err
|
||||
}
|
||||
err = regCreateKeyEx(syscall.Handle(k), pathPointer,
|
||||
0, nil, _REG_OPTION_NON_VOLATILE, access, nil, &h, &d)
|
||||
if err != nil {
|
||||
return 0, false, err
|
||||
@ -174,7 +179,11 @@ func CreateKey(k Key, path string, access uint32) (newk Key, openedExisting bool
|
||||
|
||||
// DeleteKey deletes the subkey path of key k and its values.
|
||||
func DeleteKey(k Key, path string) error {
|
||||
return regDeleteKey(syscall.Handle(k), syscall.StringToUTF16Ptr(path))
|
||||
pathPointer, err := syscall.UTF16PtrFromString(path)
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
return regDeleteKey(syscall.Handle(k), pathPointer)
|
||||
}
|
||||
|
||||
// A KeyInfo describes the statistics of a key. It is returned by Stat.
|
||||
|
6
vendor/golang.org/x/sys/windows/registry/value.go
generated
vendored
6
vendor/golang.org/x/sys/windows/registry/value.go
generated
vendored
@ -340,7 +340,11 @@ func (k Key) SetBinaryValue(name string, value []byte) error {
|
||||
|
||||
// DeleteValue removes a named value from the key k.
|
||||
func (k Key) DeleteValue(name string) error {
|
||||
return regDeleteValue(syscall.Handle(k), syscall.StringToUTF16Ptr(name))
|
||||
namePointer, err := syscall.UTF16PtrFromString(name)
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
return regDeleteValue(syscall.Handle(k), namePointer)
|
||||
}
|
||||
|
||||
// ReadValueNames returns the value names of key k.
|
||||
|
Reference in New Issue
Block a user