diff --git a/vmm/src/lib.rs b/vmm/src/lib.rs index 6da66b36d..cb1ce9d54 100644 --- a/vmm/src/lib.rs +++ b/vmm/src/lib.rs @@ -1623,7 +1623,7 @@ impl RequestHandler for Vmm { for net in restored_nets.iter() { for net_config in vm_net_configs.iter_mut() { // update only if the net dev is backed by FDs - if net_config.id == Some(net.id.clone()) && net_config.fds.is_some() { + if net_config.id.as_ref() == Some(&net.id) && net_config.fds.is_some() { net_config.fds.clone_from(&net.fds); } }