Skip to main content

WasmEdge_MemoryInstanceSetData

Function WasmEdge_MemoryInstanceSetData 

Source
pub unsafe extern "C" fn WasmEdge_MemoryInstanceSetData(
    Cxt: *mut WasmEdge_MemoryInstanceContext,
    Data: *const u8,
    Offset: u64,
    Length: u64,
) -> WasmEdge_Result
Expand description

Copy the data into a memory instance from the input buffer.

\param Cxt the WasmEdge_MemoryInstanceContext. \param Data the data buffer to copy. \param Offset the data start offset in the memory instance. \param Length the data buffer length. If the Offset + Length is larger than the data size in the memory instance, this function will fail.

\returns WasmEdge_Result. Call WasmEdge_ResultGetMessage for the error message.