mirror of
https://github.com/creack/pty.git
synced 2026-04-01 19:09:48 +09:00
Add pty_unsupported.go file in order to allow projects to import the package and still compile on other os/arch
This commit is contained in:
committed by
Keith Rarick
parent
76284c52ce
commit
7a543c8bf6
32
pty_unsupported.go
Normal file
32
pty_unsupported.go
Normal file
@@ -0,0 +1,32 @@
|
||||
// +build !linux,!darwin,!freebsd
|
||||
|
||||
package pty
|
||||
|
||||
import (
|
||||
"errors"
|
||||
"os"
|
||||
)
|
||||
|
||||
var (
|
||||
ErrUnsupported = errors.New("Unsupported")
|
||||
)
|
||||
|
||||
func open() (pty, tty *os.File, err error) {
|
||||
return nil, nil, ErrUnsupported
|
||||
}
|
||||
|
||||
func ptsname(f *os.File) (string, error) {
|
||||
return "", ErrUnsupported
|
||||
}
|
||||
|
||||
func grantpt(f *os.File) error {
|
||||
return ErrUnsupported
|
||||
}
|
||||
|
||||
func unlockpt(f *os.File) error {
|
||||
return ErrUnsupported
|
||||
}
|
||||
|
||||
func ioctl(fd, cmd, ptr uintptr) error {
|
||||
return ErrUnsupported
|
||||
}
|
||||
Reference in New Issue
Block a user