mirror of
https://github.com/fluencelabs/wasmer
synced 2025-06-24 06:01:33 +00:00
remove panic from UnsharedMemory
This commit is contained in:
@ -231,7 +231,11 @@ impl UnsharedMemory {
|
||||
MemoryType::Static => {
|
||||
UnsharedMemoryStorage::Static(StaticMemory::new(desc, &mut local)?)
|
||||
}
|
||||
MemoryType::SharedStatic => panic!("attempting to create shared unshared memory"),
|
||||
MemoryType::SharedStatic => {
|
||||
return Err(CreationError::InvalidDescriptor(
|
||||
"attempting to create shared unshared memory".to_string(),
|
||||
));
|
||||
}
|
||||
};
|
||||
|
||||
Ok(Self {
|
||||
|
Reference in New Issue
Block a user