()
| 24 | } |
| 25 | |
| 26 | func (stmt *mysqlStmt) Close() error { |
| 27 | if stmt.mc == nil || stmt.mc.closed.Load() { |
| 28 | // driver.Stmt.Close could be called more than once, thus this function |
| 29 | // had to be idempotent. See also Issue #450 and golang/go#16019. |
| 30 | // This bug has been fixed in Go 1.8. |
| 31 | // https://github.com/golang/go/commit/90b8a0ca2d0b565c7c7199ffcf77b15ea6b6db3a |
| 32 | // But we keep this function idempotent because it is safer. |
| 33 | return nil |
| 34 | } |
| 35 | |
| 36 | err := stmt.mc.writeCommandPacketUint32(comStmtClose, stmt.id) |
| 37 | stmt.mc = nil |
| 38 | return err |
| 39 | } |
| 40 | |
| 41 | func (stmt *mysqlStmt) NumInput() int { |
| 42 | return stmt.paramCount |
nothing calls this directly
no test coverage detected