mirror of
https://github.com/cloud-hypervisor/cloud-hypervisor.git
synced 2025-03-04 08:03:55 +00:00
It was incorrect to call Vec::from_raw_parts() on the address pointing to the shared memory log region since Vec is a Rust specific structure that doesn't directly translate into bytes. That's why we use the same function from std::slice in order to create a proper slice out of the memory region, which is then copied into a Vec. Signed-off-by: Sebastien Boeuf <sebastien.boeuf@intel.com>