forked from mirror/logrus
Merge pull request #493 from 0xE0F/master
Fixed compilation for Solaris
This commit is contained in:
commit
cf5e096eea
|
@ -11,7 +11,6 @@ import (
|
||||||
|
|
||||||
// IsTerminal returns true if the given file descriptor is a terminal.
|
// IsTerminal returns true if the given file descriptor is a terminal.
|
||||||
func IsTerminal(f io.Writer) bool {
|
func IsTerminal(f io.Writer) bool {
|
||||||
var termios Termios
|
|
||||||
switch v := f.(type) {
|
switch v := f.(type) {
|
||||||
case *os.File:
|
case *os.File:
|
||||||
_, err := unix.IoctlGetTermios(int(v.Fd()), unix.TCGETA)
|
_, err := unix.IoctlGetTermios(int(v.Fd()), unix.TCGETA)
|
||||||
|
|
Loading…
Reference in New Issue