kvm: fix ovs network creation issue (#9869)

This fixes the issue when create a ovs network
```
2024-10-29 16:02:45,089 WARN  [resource.wrapper.LibvirtOvsFetchInterfaceCommandWrapper] (agentRequest-Handler-2:null) (logid:e716722e) Network interface: ''cloudbr1'' not found
```

This is a regression of a previous security release
see "framework/cluster: improve cluster service, integration API server"

since we now use NetworkInterface.getByName to get network interface, we should NOT add single quotes before/after the label.
This commit is contained in:
Wei Zhou 2024-11-07 10:06:53 +01:00 committed by GitHub
parent a6cef7a78d
commit 006db90f75
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -92,7 +92,7 @@ public final class LibvirtOvsFetchInterfaceCommandWrapper extends CommandWrapper
@Override
public Answer execute(final OvsFetchInterfaceCommand command, final LibvirtComputingResource libvirtComputingResource) {
final String label = "'" + command.getLabel() + "'";
final String label = command.getLabel();
s_logger.debug("Will look for network with name-label:" + label);
try {