From 455733955ef109cdaa426b0a6b02d88dd2a05640 Mon Sep 17 00:00:00 2001 From: Arash Payan Date: Mon, 20 Nov 2023 15:03:31 -0800 Subject: [PATCH] Don't rely on syscall for password prompt --- pkg/samba/address.go | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/pkg/samba/address.go b/pkg/samba/address.go index 8c0a3af..5f68aca 100644 --- a/pkg/samba/address.go +++ b/pkg/samba/address.go @@ -7,7 +7,6 @@ import ( "os" "path" "strings" - "syscall" "github.com/urfave/cli/v2" "golang.org/x/term" @@ -50,7 +49,7 @@ func promptForPassword() (string, error) { return "", err } - b, err := term.ReadPassword(syscall.Stdin) + b, err := term.ReadPassword(int(os.Stdin.Fd())) if err != nil { return "", err }