Remove RefCell from copy_to method in io trait

This commit is contained in:
PThorpe92
2025-08-07 17:07:53 -04:00
parent 98f4e5cd2d
commit bcadcb2014

View File

@@ -68,7 +68,7 @@ pub trait File: Send + Sync {
while pos < file_size {
let chunk_size = (file_size - pos).min(BUFFER_SIZE);
// Read from source
let read_buffer = Arc::new(RefCell::new(Buffer::allocate(chunk_size, Rc::new(|_| {}))));
let read_buffer = Arc::new(Buffer::allocate(chunk_size, Rc::new(|_| {})));
let read_completion = self.pread(
pos,
Completion::new_read(read_buffer.clone(), move |_, _| {}),