esx: Fix double-free and freeing static strings in esxDomainSetAutostart
esx: Fix double-free and freeing static strings in esxDomainSetAutostart

Since commit ae83e02f3dd7fe99fed5d8159a35b666fafeafd5#l3393 the
newPowerInfo pointer itself is used to track the ownership of the
AutoStartPowerInfo object to make Coverity understand the code better.
This broke the code that unset some members of the AutoStartPowerInfo
object that should not be freed the normal way.

Instead, transfer ownership of the AutoStartPowerInfo object to the
HostAutoStartManagerConfig object before filling in the values that
need special handling. This allows to free the AutoStartPowerInfo
directly without having to deal with the special values, or to let
the old (now restored) logic handle the special values again.

Signed-off-by: Matthias Bolte <c6e6488d214fff527698d2a865d2c6ede2d17cda@googlemail.com>
Tested-by: Marcos Paulo de Souza <0b4ebe3a213a49a2bc3457b98408e6d86812eb46@gmail.com>
Reviewed-by: John Ferlan <87558058f6f829e5ec976c8ef960720af4ff9c7d@redhat.com>

fabianfreyer/libvirt,jfehlig/libvirt,eskultety/libvirt,fabianfreyer/libvirt,andreabolognani/libvirt,eskultety/libvirt,libvirt/libvirt,zippy2/libvirt,crobinso/libvirt,crobinso/libvirt,jardasgit/libvirt,jfehlig/libvirt,olafhering/libvirt,nertpinx/libvirt,crobinso/libvirt,jardasgit/libvirt,libvirt/libvirt,eskultety/libvirt,jardasgit/libvirt,nertpinx/libvirt,crobinso/libvirt,zippy2/libvirt,nertpinx/libvirt,andreabolognani/libvirt,libvirt/libvirt,nertpinx/libvirt,jardasgit/libvirt,zippy2/libvirt,nertpinx/libvirt,fabianfreyer/libvirt,fabianfreyer/libvirt,eskultety/libvirt,olafhering/libvirt,jfehlig/libvirt,andreabolognani/libvirt,eskultety/libvirt,andreabolognani/libvirt,olafhering/libvirt,zippy2/libvirt,jardasgit/libvirt,fabianfreyer/libvirt,libvirt/libvirt,olafhering/libvirt,jfehlig/libvirt,andreabolognani/libvirt