From 9262278979709181414664053523657355762707 Mon Sep 17 00:00:00 2001 From: Glenn Smith Date: Thu, 24 Apr 2025 14:46:37 -0400 Subject: std::function ==> ProgressFunction --- rust/src/download_provider.rs | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'rust/src') diff --git a/rust/src/download_provider.rs b/rust/src/download_provider.rs index 1e61c87d..6dd349e7 100644 --- a/rust/src/download_provider.rs +++ b/rust/src/download_provider.rs @@ -76,13 +76,13 @@ unsafe impl CoreArrayProviderInner for DownloadProvider { pub struct DownloadInstanceOutputCallbacks { pub write: Option usize>>, - pub progress: Option bool>>, + pub progress: Option bool>>, } pub struct DownloadInstanceInputOutputCallbacks { pub read: Option Option>>, pub write: Option usize>>, - pub progress: Option bool>>, + pub progress: Option bool>>, } pub struct DownloadResponse { @@ -121,7 +121,7 @@ impl DownloadInstance { } } - unsafe extern "C" fn o_progress_callback(ctxt: *mut c_void, progress: u64, total: u64) -> bool { + unsafe extern "C" fn o_progress_callback(ctxt: *mut c_void, progress: usize, total: usize) -> bool { let callbacks = ctxt as *mut DownloadInstanceOutputCallbacks; if let Some(func) = &mut (*callbacks).progress { (func)(progress, total) @@ -186,7 +186,7 @@ impl DownloadInstance { } } - unsafe extern "C" fn i_progress_callback(ctxt: *mut c_void, progress: u64, total: u64) -> bool { + unsafe extern "C" fn i_progress_callback(ctxt: *mut c_void, progress: usize, total: usize) -> bool { let callbacks = ctxt as *mut DownloadInstanceInputOutputCallbacks; if let Some(func) = &mut (*callbacks).progress { (func)(progress, total) -- cgit v1.3.1