Skip to content

Commit 41c6aca

Browse files
committed
libsq: Don't clear authorizer in disconnect()
The call is redundant and seems to becausing issues in cases where connection is already closed.
1 parent 5006c64 commit 41c6aca

File tree

1 file changed

+0
-7
lines changed

1 file changed

+0
-7
lines changed

libsql/src/local/connection.rs

Lines changed: 0 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -101,13 +101,6 @@ impl Connection {
101101

102102
/// Disconnect from the database.
103103
pub fn disconnect(&mut self) {
104-
// Clean up the authorizer before closing
105-
unsafe {
106-
let rc = libsql_sys::ffi::sqlite3_set_authorizer(self.handle(), None, std::ptr::null_mut());
107-
if rc != ffi::SQLITE_OK {
108-
tracing::error!("Failed to clear authorizer during disconnect");
109-
}
110-
}
111104
if Arc::get_mut(&mut self.drop_ref).is_some() {
112105
unsafe { libsql_sys::ffi::sqlite3_close_v2(self.raw) };
113106
}

0 commit comments

Comments
 (0)