mirror of
https://github.com/roc-lang/roc.git
synced 2024-11-11 05:34:11 +03:00
free allocated buffer
This commit is contained in:
parent
6527fa558e
commit
84b5f0c91e
@ -112,7 +112,10 @@ unsafe fn call_the_closure(closure_data_ptr: *const u8) -> i64 {
|
||||
let output = &*(buffer as *mut RocCallResult<()>);
|
||||
|
||||
match output.into() {
|
||||
Ok(_) => 0,
|
||||
Ok(_) => {
|
||||
std::alloc::dealloc(buffer, layout);
|
||||
0
|
||||
}
|
||||
Err(e) => panic!("failed with {}", e),
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user