@ -35,7 +35,7 @@ func main() {
defer conn.Close()
if options.password != "" {
auth(options.password).Write(conn)
fmt.Fprintf(conn, "*2\r\n$4\r\nauth\r\n$%d\r\n%s\r\n", len(options.password), options.password)
v, err := readValue(conn)
if err != nil {
fmt.Printf("unable to auth: %v\n", err)
@ -36,10 +36,6 @@ func (m maybe) val() value {
return m.value
}
func auth(password string) value {
return Array{BulkString("auth"), BulkString(password)}
func isOK(v value) bool {
vv, ok := v.(String)
if !ok {