mirror of
https://gitlab.uni-freiburg.de/opensourcevdi/virt-viewer
synced 2026-01-09 22:25:30 +00:00
ovirt: Filter everything which does not end in .iso
oVirt REST API does not provide a way to know what is a valid ISO image which can be assigned to a running VM. I've seen floppy disk images (.vfd) in a domain, which is already filtered. Now I've seen an ISO domain with .qcow2 files in it, which can't be assigned to a VM either. This commit filters every file which does not have a .iso extension as it's unlikely to be possible to use it. Signed-off-by: Christophe Fergeau <cfergeau@redhat.com> Acked-by: Eduardo Lima (Etrunko) <etrunko@redhat.com>
This commit is contained in:
parent
1b45241a66
commit
71dc30571e
@ -489,7 +489,8 @@ static void ovirt_foreign_menu_set_files(OvirtForeignMenu *menu,
|
||||
* associated with file resources , but as of 3.2, this node
|
||||
* is not present, so we do an extension check instead
|
||||
* to differentiate between ISOs and floppy images */
|
||||
if (g_str_has_suffix(name, ".vfd")) {
|
||||
if (!g_str_has_suffix(name, ".iso")) {
|
||||
g_debug("Ignoring %s which does not have a .iso extension", name);
|
||||
g_free(name);
|
||||
continue;
|
||||
}
|
||||
|
||||
Loading…
Reference in New Issue
Block a user