mirror of
https://github.com/isar/rusqlite.git
synced 2025-09-16 04:32:19 +08:00
Implement our own sqlite3_exec
Should fix issue related to unlock notify: #767 Caveat: many CString allocated.
This commit is contained in:
@@ -622,7 +622,7 @@ impl Statement<'_> {
|
||||
}
|
||||
|
||||
fn finalize_(&mut self) -> Result<()> {
|
||||
let mut stmt = unsafe { RawStatement::new(ptr::null_mut(), false) };
|
||||
let mut stmt = unsafe { RawStatement::new(ptr::null_mut(), 0) };
|
||||
mem::swap(&mut stmt, &mut self.stmt);
|
||||
self.conn.decode_result(stmt.finalize())
|
||||
}
|
||||
@@ -707,7 +707,7 @@ impl Statement<'_> {
|
||||
/// connection has closed is illegal, but `RawStatement` does not enforce
|
||||
/// this, as it loses our protective `'conn` lifetime bound.
|
||||
pub(crate) unsafe fn into_raw(mut self) -> RawStatement {
|
||||
let mut stmt = RawStatement::new(ptr::null_mut(), false);
|
||||
let mut stmt = RawStatement::new(ptr::null_mut(), 0);
|
||||
mem::swap(&mut stmt, &mut self.stmt);
|
||||
stmt
|
||||
}
|
||||
|
Reference in New Issue
Block a user