mirror of https://gitee.com/openkylin/libvirt.git
conf: net: Fix helper for applying new network definition
When there's no new definition the helper overwrote the old one with NULL.
This commit is contained in:
parent
d055498d04
commit
947230fb56
|
@ -359,7 +359,7 @@ virNetworkObjSetDefTransient(virNetworkObjPtr network, bool live)
|
|||
void
|
||||
virNetworkObjUnsetDefTransient(virNetworkObjPtr network)
|
||||
{
|
||||
if (network->def) {
|
||||
if (network->newDef) {
|
||||
virNetworkDefFree(network->def);
|
||||
network->def = network->newDef;
|
||||
network->newDef = NULL;
|
||||
|
|
Loading…
Reference in New Issue