Skip to content
Browse files

fix #46 - ignore all notices

  • Loading branch information...
1 parent 3eb53ef commit 948ed42a8a2f6dc656706e55c2fb0dffcfe70f7d @bmizerany committed Oct 8, 2012
Showing with 6 additions and 6 deletions.
  1. +6 −6 conn.go
View
12 conn.go
@@ -158,9 +158,7 @@ func (cn *conn) simpleQuery(q string) (res driver.Result, err error) {
return
case 'E':
err = parseError(r)
- case 'N':
- // ignore
- case 'T':
+ case 'T', 'N':
// ignore
default:
errorf("unknown response for simple query: %q", t)
@@ -190,7 +188,7 @@ func (cn *conn) prepareTo(q, stmtName string) (_ driver.Stmt, err error) {
for {
t, r := cn.recv1()
switch t {
- case '1', '2':
+ case '1', '2', 'N':
case 't':
st.nparams = int(r.int16())
case 'T':
@@ -276,7 +274,7 @@ func (cn *conn) recv() (t byte, r *readBuf) {
case 'E':
panic(parseError(r))
case 'N':
- // TODO(bmizerany): log notices?
+ // ignore
default:
return
}
@@ -494,6 +492,8 @@ func (st *stmt) exec(v []driver.Value) {
panic(err)
}
return
+ case 'N':
+ // ignore
default:
errorf("unexpected bind response: %q", t)
}
@@ -555,7 +555,7 @@ func (rs *rows) Next(dest []driver.Value) (err error) {
switch t {
case 'E':
err = parseError(r)
- case 'C', 'S':
+ case 'C', 'S', 'N':
continue
case 'Z':
rs.done = true

0 comments on commit 948ed42

Please sign in to comment.
Something went wrong with that request. Please try again.