1
0
Fork 0

Use original driver for queries

This commit is contained in:
Gregory Eremin 2018-11-14 15:56:08 +01:00
parent cba0886b24
commit 5e2f862e2b
3 changed files with 3 additions and 3 deletions

View File

@ -4,7 +4,7 @@ import (
"context"
"database/sql"
_ "github.com/localhots/mysql" // MySQL driver
_ "github.com/go-sql-driver/mysql" // MySQL driver
"github.com/juju/errors"
"github.com/localhots/bocadillo/binlog"

View File

@ -67,7 +67,7 @@ func (r *Reader) ReadEvent() (*Event, error) {
return nil, errors.Annotate(err, "read next event")
}
evt := Event{Format: r.format}
evt := Event{Format: r.format, Offset: r.state.Offset}
if err := evt.Header.Decode(connBuff, r.format); err != nil {
return nil, errors.Annotate(err, "decode event header")
}

View File

@ -7,7 +7,7 @@ import (
"strconv"
"testing"
_ "github.com/localhots/mysql"
_ "github.com/go-sql-driver/mysql"
"github.com/localhots/bocadillo/binlog"
"github.com/localhots/bocadillo/reader"