avoid syscall
This commit is contained in:
parent
0d1285f1e0
commit
f1738c2aa6
|
|
@ -2,9 +2,9 @@ package poller
|
||||||
|
|
||||||
import (
|
import (
|
||||||
"fmt"
|
"fmt"
|
||||||
|
"os"
|
||||||
"strconv"
|
"strconv"
|
||||||
"strings"
|
"strings"
|
||||||
"syscall"
|
|
||||||
|
|
||||||
"golang.org/x/crypto/bcrypt"
|
"golang.org/x/crypto/bcrypt"
|
||||||
"golang.org/x/crypto/ssh/terminal"
|
"golang.org/x/crypto/ssh/terminal"
|
||||||
|
|
@ -41,7 +41,7 @@ func (u *UnifiPoller) PrintPasswordHash() (err error) {
|
||||||
if u.Flags.HashPW == "-" {
|
if u.Flags.HashPW == "-" {
|
||||||
fmt.Print("Enter Password: ")
|
fmt.Print("Enter Password: ")
|
||||||
|
|
||||||
pwd, err = terminal.ReadPassword(int(syscall.Stdin))
|
pwd, err = terminal.ReadPassword(int(os.Stdin.Fd()))
|
||||||
if err != nil {
|
if err != nil {
|
||||||
return err
|
return err
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue