mirror of
https://github.com/chatmail/core.git
synced 2026-04-17 21:46:35 +03:00
Use usize to get pointer size
According to Rust documentation, usize is "The pointer-sized unsigned integer type". This change removes unnecessary libc dependency and makes top_evil_rs script happier.
This commit is contained in:
@@ -79,12 +79,7 @@ pub fn get_info() -> HashMap<&'static str, String> {
|
||||
"sqlite_thread_safe",
|
||||
unsafe { rusqlite::ffi::sqlite3_threadsafe() }.to_string(),
|
||||
);
|
||||
res.insert(
|
||||
"arch",
|
||||
(std::mem::size_of::<*mut libc::c_void>())
|
||||
.wrapping_mul(8)
|
||||
.to_string(),
|
||||
);
|
||||
res.insert("arch", (std::mem::size_of::<usize>() * 8).to_string());
|
||||
res.insert("level", "awesome".into());
|
||||
res
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user