mirror of
https://github.com/isar/rusqlite.git
synced 2024-11-26 11:31:37 +08:00
Rustfmt
This commit is contained in:
parent
0b42e3c78c
commit
13c93e0f8b
@ -490,7 +490,8 @@ impl InnerConnection {
|
|||||||
T: ToResult
|
T: ToResult
|
||||||
{
|
{
|
||||||
let boxed_aggr: *mut D = mem::transmute(ffi::sqlite3_user_data(ctx));
|
let boxed_aggr: *mut D = mem::transmute(ffi::sqlite3_user_data(ctx));
|
||||||
assert!(!boxed_aggr.is_null(), "Internal error - null aggregate pointer");
|
assert!(!boxed_aggr.is_null(),
|
||||||
|
"Internal error - null aggregate pointer");
|
||||||
|
|
||||||
// TODO Validate: double indirection: `pac` allocated/freed by SQLite and `ac` allocated/freed by Rust.
|
// TODO Validate: double indirection: `pac` allocated/freed by SQLite and `ac` allocated/freed by Rust.
|
||||||
let pac = ffi::sqlite3_aggregate_context(ctx, ::std::mem::size_of::<*mut A>() as c_int) as *mut *mut A;
|
let pac = ffi::sqlite3_aggregate_context(ctx, ::std::mem::size_of::<*mut A>() as c_int) as *mut *mut A;
|
||||||
@ -517,7 +518,8 @@ impl InnerConnection {
|
|||||||
T: ToResult
|
T: ToResult
|
||||||
{
|
{
|
||||||
let boxed_aggr: *mut D = mem::transmute(ffi::sqlite3_user_data(ctx));
|
let boxed_aggr: *mut D = mem::transmute(ffi::sqlite3_user_data(ctx));
|
||||||
assert!(!boxed_aggr.is_null(), "Internal error - null aggregate pointer");
|
assert!(!boxed_aggr.is_null(),
|
||||||
|
"Internal error - null aggregate pointer");
|
||||||
|
|
||||||
let pac = ffi::sqlite3_aggregate_context(ctx, 0) as *mut *mut A;
|
let pac = ffi::sqlite3_aggregate_context(ctx, 0) as *mut *mut A;
|
||||||
if pac.is_null() || (*pac).is_null() {
|
if pac.is_null() || (*pac).is_null() {
|
||||||
|
Loading…
Reference in New Issue
Block a user