diff options
author | scheidell <scheidell@FreeBSD.org> | 2012-01-19 09:53:50 +0800 |
---|---|---|
committer | scheidell <scheidell@FreeBSD.org> | 2012-01-19 09:53:50 +0800 |
commit | 3f108c70addfe6f917649b50d5f660c946cc59aa (patch) | |
tree | 52aec501dd626016ec8bc2a12bb63e53181f043d /databases | |
parent | 148d7f8ab59f762fe57a4a630f6971509a6fbd9c (diff) | |
download | freebsd-ports-gnome-3f108c70addfe6f917649b50d5f660c946cc59aa.tar.gz freebsd-ports-gnome-3f108c70addfe6f917649b50d5f660c946cc59aa.tar.zst freebsd-ports-gnome-3f108c70addfe6f917649b50d5f660c946cc59aa.zip |
- Fixed authenticaton to database != 0
PR: ports/164295
Submitted by: maintainer
Approved by: gabor (maintainer, implicit)
Diffstat (limited to 'databases')
-rw-r--r-- | databases/godis/Makefile | 2 | ||||
-rw-r--r-- | databases/godis/files/patch-conn.go | 24 |
2 files changed, 25 insertions, 1 deletions
diff --git a/databases/godis/Makefile b/databases/godis/Makefile index 87ce0259d0b5..30c5296cffa6 100644 --- a/databases/godis/Makefile +++ b/databases/godis/Makefile @@ -7,7 +7,7 @@ PORTNAME= godis PORTVERSION= 20110803 -PORTREVISION= 2 +PORTREVISION= 3 CATEGORIES= databases MASTER_SITES= LOCAL/jlaffaye diff --git a/databases/godis/files/patch-conn.go b/databases/godis/files/patch-conn.go new file mode 100644 index 000000000000..2ebb27bcd9d1 --- /dev/null +++ b/databases/godis/files/patch-conn.go @@ -0,0 +1,24 @@ +--- conn.go.orig 2011-09-04 22:00:03.000000000 +0200 ++++ conn.go 2012-01-18 21:31:25.000000000 +0100 +@@ -342,8 +342,8 @@ + } + + func (cc *conn) configConn(db int, password string) os.Error { +- if db != 0 { +- buf := [][]byte{[]byte("SELECT"), []byte(strconv.Itoa(db))} ++ if password != "" { ++ buf := [][]byte{[]byte("AUTH"), []byte(password)} + _, err := cc.rwc.Write(buildCmd(buf)) + + if err != nil { +@@ -356,8 +356,8 @@ + } + } + +- if password != "" { +- buf := [][]byte{[]byte("AUTH"), []byte(password)} ++ if db != 0 { ++ buf := [][]byte{[]byte("SELECT"), []byte(strconv.Itoa(db))} + _, err := cc.rwc.Write(buildCmd(buf)) + + if err != nil {
\ No newline at end of file |