Testing patherror fix.
This commit is contained in:
parent
e7b4f5344e
commit
8f6f06dfea
1 changed files with 6 additions and 2 deletions
8
stty.go
8
stty.go
|
@ -1,10 +1,12 @@
|
||||||
package stty
|
package stty
|
||||||
|
|
||||||
import (
|
import (
|
||||||
|
"fmt"
|
||||||
"os"
|
"os"
|
||||||
"golang.org/x/sys/unix"
|
|
||||||
"golang.org/x/term"
|
|
||||||
"os/exec"
|
"os/exec"
|
||||||
|
|
||||||
|
"golang.org/x/sys/unix"
|
||||||
|
"golang.org/x/term"
|
||||||
)
|
)
|
||||||
|
|
||||||
type stty interface{
|
type stty interface{
|
||||||
|
@ -31,6 +33,8 @@ func init() {
|
||||||
func ValidateTtyFile(filepath string) error {
|
func ValidateTtyFile(filepath string) error {
|
||||||
file, err := os.Open(filepath)
|
file, err := os.Open(filepath)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
|
fmt.Println(err)
|
||||||
|
fmt.Println(err.Error())
|
||||||
return errStack(ERR_CANNOT_OPEN_FILE(), err)
|
return errStack(ERR_CANNOT_OPEN_FILE(), err)
|
||||||
}
|
}
|
||||||
defer file.Close()
|
defer file.Close()
|
||||||
|
|
Loading…
Add table
Reference in a new issue