Avoid pointless recursive call
This commit is contained in:
@@ -463,7 +463,6 @@ func (c *Conn) Query(sql string, args ...interface{}) (*Rows, error) {
|
|||||||
func (c *Conn) getRows(sql string, args []interface{}) *Rows {
|
func (c *Conn) getRows(sql string, args []interface{}) *Rows {
|
||||||
if len(c.preallocatedRows) == 0 {
|
if len(c.preallocatedRows) == 0 {
|
||||||
c.preallocatedRows = make([]Rows, 64)
|
c.preallocatedRows = make([]Rows, 64)
|
||||||
return c.getRows(sql, args)
|
|
||||||
}
|
}
|
||||||
|
|
||||||
r := &c.preallocatedRows[len(c.preallocatedRows)-1]
|
r := &c.preallocatedRows[len(c.preallocatedRows)-1]
|
||||||
|
|||||||
Reference in New Issue
Block a user