Gitiles
Code Review
Sign In
gerrit.opencord.org
/
voltha-lib-go
/
b950321bae3dfbc8a6f5369fddac8dfb9a2d0834
/
.
/
vendor
/
github.com
/
sirupsen
/
logrus
/
terminal_check_unix.go
blob: cc4fe6e317769b4bd05e43f820a5d582bf222097 [
file
] [
log
] [
blame
]
// +build linux aix
// +build !js
package logrus
import "golang.org/x/sys/unix"
const ioctlReadTermios = unix.TCGETS
func isTerminal(fd int) bool {
_, err := unix.IoctlGetTermios(fd, ioctlReadTermios)
return err == nil
}