summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMichael Steinert <[email protected]>2015-04-10 23:36:35 -0500
committerMichael Steinert <[email protected]>2015-04-11 13:27:31 -0500
commit9a42d39dbf2c9f3deeddb4e9f72ba83e2ef59f2d (patch)
treef36ac3c61c23cb0eff825d9c25b6aa6f3acb1383
parent8b3b6781b0882eb5493539bf7e521dd98ad1f626 (diff)
Update example
-rw-r--r--example/example.go10
1 files changed, 5 insertions, 5 deletions
diff --git a/example/example.go b/example/example.go
index efe0d79..38d0627 100644
--- a/example/example.go
+++ b/example/example.go
@@ -21,12 +21,13 @@ package main
import (
"bufio"
- "code.google.com/p/gopass"
"errors"
"fmt"
- "github.com/msteinert/pam"
"log"
"os"
+
+ "code.google.com/p/gopass"
+ "github.com/msteinert/pam"
)
func main() {
@@ -35,9 +36,8 @@ func main() {
case pam.PromptEchoOff:
return gopass.GetPass(msg)
case pam.PromptEchoOn:
- fmt.Print(msg)
- bio := bufio.NewReader(os.Stdin)
- input, err := bio.ReadString('\n')
+ fmt.Print(msg + " ")
+ input, err := bufio.NewReader(os.Stdin).ReadString('\n')
if err != nil {
return "", err
}