1 // Copyright 2015 The Go Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style
3 // license that can be found in the LICENSE file.
5 // +build dragonfly freebsd linux netbsd openbsd
12 extraTestHookInstallers
= append(extraTestHookInstallers
, installAccept4TestHook
)
13 extraTestHookUninstallers
= append(extraTestHookUninstallers
, uninstallAccept4TestHook
)
17 // Placeholders for saving original socket system calls.
18 origAccept4
= poll
.Accept4Func
21 func installAccept4TestHook() {
22 poll
.Accept4Func
= sw
.Accept4
25 func uninstallAccept4TestHook() {
26 poll
.Accept4Func
= origAccept4