Skip to content

Commit 7ab00bd

Browse files
committed
cgosqlite: cleanup two unnecessary unsafe casts
The type is already compatible directly out of the API so there's no need for the cast dance in these calls. Updates #cleanup
1 parent 81bdfd0 commit 7ab00bd

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

cgosqlite/cgosqlite.go

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -244,11 +244,11 @@ func (stmt *Stmt) StartTimer() {
244244
}
245245

246246
func (stmt *Stmt) ColumnDatabaseName(col int) string {
247-
return C.GoString((*C.char)(unsafe.Pointer(C.sqlite3_column_database_name(stmt.stmt, C.int(col)))))
247+
return C.GoString(C.sqlite3_column_database_name(stmt.stmt, C.int(col)))
248248
}
249249

250250
func (stmt *Stmt) ColumnTableName(col int) string {
251-
return C.GoString((*C.char)(unsafe.Pointer(C.sqlite3_column_table_name(stmt.stmt, C.int(col)))))
251+
return C.GoString(C.sqlite3_column_table_name(stmt.stmt, C.int(col)))
252252
}
253253

254254
func (stmt *Stmt) Step(colType []sqliteh.ColumnType) (row bool, err error) {

0 commit comments

Comments
 (0)