fix(runtime-c-api) Change mutability of memory for const in wasmer_memory_data_length.

This commit is contained in:
Ivan Enderlin
2020-03-26 07:30:34 +01:00
parent 4703e78250
commit 9826ff3813

View File

@ -198,7 +198,7 @@ pub extern "C" fn wasmer_memory_data(memory: *const wasmer_memory_t) -> *mut u8
/// ```
#[allow(clippy::cast_ptr_alignment)]
#[no_mangle]
pub extern "C" fn wasmer_memory_data_length(memory: *mut wasmer_memory_t) -> u32 {
pub extern "C" fn wasmer_memory_data_length(memory: *const wasmer_memory_t) -> u32 {
if memory.is_null() {
return 0;
}