windows: revert breaking API changes from CL 196798, add new accessor funcs

CL 196798 changed API and broke a number of projects.

Revert the signature changes but add new convenience functions instead.

Change-Id: I49e389204f4756ec054ba8fd7555e235ef6370e8
Reviewed-on: https://go-review.googlesource.com/c/sys/+/197597
Run-TryBot: Brad Fitzpatrick <bradfitz@golang.org>
Reviewed-by: Bryan C. Mills <bcmills@google.com>
This commit is contained in:
Brad Fitzpatrick
2019-09-26 18:03:25 +00:00
parent 2837fb4f24
commit 855e68c859
3 changed files with 23 additions and 7 deletions
+1 -1
View File
@@ -246,7 +246,7 @@ func TestGetNamedSecurityInfo(t *testing.T) {
}
func TestGetSecurityInfo(t *testing.T) {
sd, err := windows.GetSecurityInfo(windows.GetCurrentProcess(), windows.SE_KERNEL_OBJECT, windows.DACL_SECURITY_INFORMATION)
sd, err := windows.GetSecurityInfo(windows.CurrentProcess(), windows.SE_KERNEL_OBJECT, windows.DACL_SECURITY_INFORMATION)
if err != nil {
t.Fatal(err)
}