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

Fix crash when setting custom VM icon (#2387) #2742

Merged
merged 1 commit into from
Aug 26, 2021

Conversation

ktprograms
Copy link
Contributor

It turns out there were two unrelated problems.

First, and caused the crash (Line 199):
The first time you set a custom icon, the self.configuration.icon is nil, which crashes NSURL's - (nullable NSURL *)URLByAppendingPathComponent:(NSString *)pathComponent. I changed the code to check for self.configuration.icon being nil so it would skip over the deleting the previous icon.

Second, fix custom icon not being set creating a new VM (Line 143):
The setting self.configuration with the configuration parameter wasn't setting the selectedCustomIconPath. I added an extra line to also set just the selectedCustomIconPath.

@osy osy merged commit 94eed42 into utmapp:master Aug 26, 2021
@ktprograms ktprograms deleted the fix-set-vm-icon branch August 26, 2021 06:11
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants