blob: 721b9f9f7e33233a07d3c965504d7fdc6f0c707b [file] [log] [blame]
Dan Willemsen38f2dba2016-07-08 14:54:35 -07001// Copyright 2016 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.
4
Dan Willemsenbc60c3c2021-12-15 01:09:00 -08005// aix, darwin, js/wasm, openbsd and solaris don't implement
6// waitid/wait6. netbsd implements wait6, but that is causing test
7// failures, see issue #48789.
8
9//go:build aix || darwin || (js && wasm) || netbsd || openbsd || solaris
Dan Willemsen38f2dba2016-07-08 14:54:35 -070010
11package os
12
13// blockUntilWaitable attempts to block until a call to p.Wait will
Colin Crossd9c6b802019-03-19 21:10:31 -070014// succeed immediately, and reports whether it has done so.
Dan Willemsen38f2dba2016-07-08 14:54:35 -070015// It does not actually call p.Wait.
16// This version is used on systems that do not implement waitid,
Dan Willemsenbc60c3c2021-12-15 01:09:00 -080017// or where we have not implemented it yet. Note that this is racy:
18// a call to Process.Signal can in an extremely unlikely case send a
19// signal to the wrong process, see issue #13987.
Dan Willemsen38f2dba2016-07-08 14:54:35 -070020func (p *Process) blockUntilWaitable() (bool, error) {
21 return false, nil
22}