aboutsummaryrefslogtreecommitdiff
path: root/src/database/sql/sql.go
diff options
context:
space:
mode:
Diffstat (limited to 'src/database/sql/sql.go')
-rw-r--r--src/database/sql/sql.go12
1 files changed, 0 insertions, 12 deletions
diff --git a/src/database/sql/sql.go b/src/database/sql/sql.go
index 9a3957b267..17910904f6 100644
--- a/src/database/sql/sql.go
+++ b/src/database/sql/sql.go
@@ -2491,12 +2491,6 @@ func (rs *Rows) nextLocked() (doClose, ok bool) {
if rs.lastcols == nil {
rs.lastcols = make([]driver.Value, len(rs.rowsi.Columns()))
}
-
- // Lock the driver connection before calling the driver interface
- // rowsi to prevent a Tx from rolling back the connection at the same time.
- rs.dc.Lock()
- defer rs.dc.Unlock()
-
rs.lasterr = rs.rowsi.Next(rs.lastcols)
if rs.lasterr != nil {
// Close the connection if there is a driver error.
@@ -2546,12 +2540,6 @@ func (rs *Rows) NextResultSet() bool {
doClose = true
return false
}
-
- // Lock the driver connection before calling the driver interface
- // rowsi to prevent a Tx from rolling back the connection at the same time.
- rs.dc.Lock()
- defer rs.dc.Unlock()
-
rs.lasterr = nextResultSet.NextResultSet()
if rs.lasterr != nil {
doClose = true