Merge pull request #1421 from gwenn/test_from_handle

Apply patch
This commit is contained in:
gwenn 2023-12-16 10:28:50 +01:00 committed by GitHub
commit aeaacc402a
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -1881,7 +1881,7 @@ mod test {
#[test]
fn test_from_handle_owned() -> Result<()> {
let mut handle: *mut ffi::sqlite3 = std::ptr::null_mut();
let r = unsafe { ffi::sqlite3_open(":memory:\0".as_ptr() as *const i8, &mut handle) };
let r = unsafe { ffi::sqlite3_open(":memory:\0".as_ptr() as *const c_char, &mut handle) };
assert_eq!(r, ffi::SQLITE_OK);
let db = unsafe { Connection::from_handle_owned(handle) }?;
db.execute_batch("PRAGMA VACUUM")?;