agent/device: Correct misleading error message in update_spec_device()

This error is returned if we have information for a device from the
runtime, but a matching device does not appear in the OCI spec.  However,
the name for the device we print is the name from the VM, rather than the
name from the container which is what we actually expect in the spec.

Signed-off-by: David Gibson <david@gibson.dropbear.id.au>
This commit is contained in:
David Gibson 2021-11-04 16:47:45 +11:00
parent 94b7936f51
commit 0c51da3dd0

View File

@ -511,8 +511,8 @@ fn update_spec_device(
Ok(())
} else {
Err(anyhow!(
"Should have found a matching device {} in the spec",
vm_path
"Should have found a device {} in the spec",
host_path
))
}
}