Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

QEMU custom arguments cannot contain spaces. #3579

Closed
adespoton opened this issue Feb 4, 2022 · 2 comments
Closed

QEMU custom arguments cannot contain spaces. #3579

adespoton opened this issue Feb 4, 2022 · 2 comments
Labels
settings Anything in the setting/create views
Milestone

Comments

@adespoton
Copy link

Describe the issue
When putting paths or parameters into a QEMU argument, UTM's parser appears to use spaces as breaks, no matter whether the string is single or double quoted or the spaces are escaped.
So "path/to this/file.qcow2", 'path/to this/file.qcow2' and path/to\ this/file.qcow2 all break.

While drive paths can be handled by removing the actual spaces in file names and directory names, setting a device label to a product string containing spaces is a bigger issue, such as:

-device scsi-cd,scsi-id=3,drive=cd1,vendor="MATSHITA",product="CD-ROM CR-8005",ver="1.0k"

UTM will split this at CD-ROM, which results in an error when you attempt to run the VM. Of course, the hardware in question won't recognize the CD-ROM drive without this label, so it can't just be modified to remove the space.

Configuration

  • UTM Version: 2.x and 3.x up to 3.0.4
  • OS Version: macOS 12.2
  • Apple Silicon
@osy
Copy link
Contributor

osy commented Feb 4, 2022

We currently support quotes at the start and end of an argument but not in middle of one https://github.com/utmapp/UTM/blob/master/Managers/UTMQemuSystem.m#L703

@osy osy added the settings Anything in the setting/create views label Feb 4, 2022
@adespoton
Copy link
Author

Wouldn't it make more sense to split at \S- instead of at \S? QEMU requires argument markers for all arguments.

@osy osy added this to the v3.1 milestone Feb 7, 2022
@osy osy closed this as completed in 0bc74f8 Feb 13, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
settings Anything in the setting/create views
Projects
None yet
Development

No branches or pull requests

2 participants