summary refs log tree commit diff
path: root/host/start-vm
diff options
context:
space:
mode:
authorAlyssa Ross <hi@alyssa.is>2023-06-23 22:47:06 +0000
committerAlyssa Ross <hi@alyssa.is>2023-06-24 08:52:59 +0000
commitf2f8f9099f9c5908b29e3fb429dc61911acf264c (patch)
treea29b385a97cc521a49e83cc0cb6d83748bb2a4ab /host/start-vm
parent1451aebd1bf85ca35d3d1f0f422be15eb5c58e0d (diff)
downloadspectrum-f2f8f9099f9c5908b29e3fb429dc61911acf264c.tar
spectrum-f2f8f9099f9c5908b29e3fb429dc61911acf264c.tar.gz
spectrum-f2f8f9099f9c5908b29e3fb429dc61911acf264c.tar.bz2
spectrum-f2f8f9099f9c5908b29e3fb429dc61911acf264c.tar.lz
spectrum-f2f8f9099f9c5908b29e3fb429dc61911acf264c.tar.xz
spectrum-f2f8f9099f9c5908b29e3fb429dc61911acf264c.tar.zst
spectrum-f2f8f9099f9c5908b29e3fb429dc61911acf264c.zip
host/start-vm: remove no-op code
This turns dir from a PathBuf into an OsString, then into a Vec<u8>,
then back into an OsString, then back into a PathBuf, to no end.

Fixes: ab9d7bf ("host/start-vm: use returns instead of early exits")
Signed-off-by: Alyssa Ross <hi@alyssa.is>
Diffstat (limited to 'host/start-vm')
-rw-r--r--host/start-vm/lib.rs3
1 files changed, 0 insertions, 3 deletions
diff --git a/host/start-vm/lib.rs b/host/start-vm/lib.rs
index c4afc4a..7e34cd1 100644
--- a/host/start-vm/lib.rs
+++ b/host/start-vm/lib.rs
@@ -49,9 +49,6 @@ pub fn vm_command(
     config_root: &Path,
     api_socket_fd: RawFd,
 ) -> Result<Command, String> {
-    let dir = dir.into_os_string().into_vec();
-    let dir = PathBuf::from(OsString::from_vec(dir));
-
     let vm_name = dir
         .file_name()
         .ok_or_else(|| "directory has no name".to_string())?;