Initial windows runtime work
Signed-off-by: Kenfe-Mickael Laventure <mickael.laventure@gmail.com>
This commit is contained in:
16
sys/socket_windows.go
Normal file
16
sys/socket_windows.go
Normal file
@@ -0,0 +1,16 @@
|
||||
// +build windows
|
||||
|
||||
package sys
|
||||
|
||||
import (
|
||||
"net"
|
||||
|
||||
"github.com/Microsoft/go-winio"
|
||||
)
|
||||
|
||||
// GetLocalListener returns a Listernet out of a named pipe.
|
||||
// `path` must be of the form of `\\.\pipe\<pipename>`
|
||||
// (see https://msdn.microsoft.com/en-us/library/windows/desktop/aa365150)
|
||||
func GetLocalListener(path string, uid, gid int) (net.Listener, error) {
|
||||
return winio.ListenPipe(path, nil)
|
||||
}
|
Reference in New Issue
Block a user