The new fix for shutdown-on-init on Focal is simpler: Skip the XML update on init if libvirt is shutting down.
This is based on 2 points:
1) The XML update on initialization will not be used at all in this run of libvirtd, since libvirtd is shutting down.
2) The XML update in _this_ initialization will be overwritten by the XML update in the _next_ initialization anyway!
Hence, it is OK to skip this XML update if shutting down.
The new fix for shutdown-on-init on Focal is simpler:
Skip the XML update on init if libvirt is shutting down.
This is based on 2 points:
1) The XML update on initialization will not be used at all
in this run of libvirtd, since libvirtd is shutting down.
2) The XML update in _this_ initialization will be overwritten
by the XML update in the _next_ initialization anyway!
Hence, it is OK to skip this XML update if shutting down.