Skip to content

Commit 7e6847f

Browse files
committed
more smaller fixes
Signed-off-by: Narfinger <[email protected]>
1 parent 969b7e4 commit 7e6847f

File tree

2 files changed

+2
-5
lines changed

2 files changed

+2
-5
lines changed

src/ipc.rs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -700,6 +700,7 @@ impl IpcSharedMemoryVec {
700700
}
701701
}
702702

703+
#[derive(Clone)]
703704
pub struct IpcSharedMemoryReader(OsIpcSharedMemoryVec);
704705

705706
impl IpcSharedMemoryReader {

src/platform/unix/mod.rs

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -907,11 +907,7 @@ impl OsIpcSharedMemoryVec {
907907
self.store.fd,
908908
0,
909909
);
910-
ptr::copy_nonoverlapping(
911-
bytes.as_ptr(),
912-
self.ptr.byte_offset(self.length as isize),
913-
bytes.len(),
914-
);
910+
ptr::copy_nonoverlapping(bytes.as_ptr(), address as *mut u8, bytes.len());
915911
OsIpcSharedMemoryIndex {
916912
offset: self.length,
917913
length: bytes.len(),

0 commit comments

Comments
 (0)