microsoft/go-winio

[v0.4.14] GetCurrentProcess mismatch between golang.org/x/sys/windows

vishwaspai opened this issue · 3 comments

When using latest golang.org/x/sys/windows (golang.org/x/sys - version: 2aa67d56cdd77167a5fb51358e8c3ce04bad68bb) we are hitting following mismatch on GetCurrentProcess().

  • vendor/github.com/Microsoft/go-winio
    vendor/github.com/Microsoft/go-winio/privilege.go:129:7: assignment mismatch: 2 variables but "golang.org/x/sys/windows".GetCurrentProcess returns 1 values

Looks like the new def in golang.org/x/sys/windows is returns only 1 argument (no error)

import: golang.org/x/sys/windows
Old:
syscall_windows.go://sys GetCurrentProcess() (pseudoHandle Handle, err error)

New:
syscall_windows.go://sys GetCurrentProcess() (pseudoHandle Handle)

--
Thanks in advance for taking a look at this issue. Please let me know if this is not the right place for this issue.

This also break prometheus:

# github.com/prometheus/client_golang/prometheus
../../go/pkg/mod/github.com/prometheus/client_golang@v1.1.1-0.20190913103102-20428fa0bffc/prometheus/process_collector_windows.go:78:9: assignment mismatch: 2 variables but 1 values

Who has any suguestion?

With latest golang.org/x/sys/windows, this is no longer an issue. If others are not facing the issue, this can be closed.