MCPcopy Create free account
hub / github.com/PLSysSec/wave / write_method_6

Function write_method_6

src/tests/memwrite_experiment.rs:91–99  ·  view source on GitHub ↗

Method 6: copy_non_overlapping (memcpy)

(ctx: &mut VmCtx, src: &[u8], offset:usize)

Source from the content-addressed store, hash-verified

89
90// Method 6: copy_non_overlapping (memcpy)
91fn write_method_6(ctx: &mut VmCtx, src: &[u8], offset:usize){
92 unsafe {
93 copy_nonoverlapping(
94 src.as_ptr(),
95 self.mem.as_mut_ptr().offset(offset as isize),
96 src.len(),
97 )
98 };
99}
100
101// Method 7: copy (memmove)
102fn write_method_7(ctx: &mut VmCtx, src: &[u8], offset:usize){

Callers

nothing calls this directly

Calls 1

lenMethod · 0.45

Tested by

no test coverage detected