Skip to content

Commit 0ad09d4

Browse files
Don't copy sql.Stmt because this also copies the mutex closemu
1 parent 0dae4fe commit 0ad09d4

File tree

2 files changed

+0
-4
lines changed

2 files changed

+0
-4
lines changed

sqlx.go

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -471,8 +471,6 @@ func (tx *Tx) Stmtx(stmt interface{}) *Stmt {
471471
s = v.Stmt
472472
case *Stmt:
473473
s = v.Stmt
474-
case sql.Stmt:
475-
s = &v
476474
case *sql.Stmt:
477475
s = v
478476
default:

sqlx_context.go

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -217,8 +217,6 @@ func (tx *Tx) StmtxContext(ctx context.Context, stmt interface{}) *Stmt {
217217
s = v.Stmt
218218
case *Stmt:
219219
s = v.Stmt
220-
case sql.Stmt:
221-
s = &v
222220
case *sql.Stmt:
223221
s = v
224222
default:

0 commit comments

Comments
 (0)