libvirt/src/qemu
Eric Blake ceb1019257 snapshot: Don't leak moment obj list metaroot to callers
virDomainSnapshotFindByName(list, NULL) should return NULL, rather
than the internal-use-only metaroot.  Most existing callers pass in a
non-NULL name; the few external callers that don't are immediately
calling virDomainMomentSetParent (which indeed needs the metaroot
rather than NULL if the parent name is NULL); but as the leaky
abstraction is ugly, it is worth instead making
virDomainMomentSetParent static and adding a new function for
resolving the parent link of a brand new moment within its list.  The
existing external uses of virDomainMomentSetParent always succeed
(either the new moment has parent_name of NULL to become a new root,
or has parent_name set to a strdup of the previous current moment);
hence, our new function does not need a return value (but it still has
a VIR_WARN in case future uses break our assumptions about failure
being impossible).

Missed when commit 02c4e24d refactored things to attempt to remove
direct metaroot manipulations out of the qemu and test drivers into
internal-only details, and made more obvious when commit dc8d3dc6
factored it out into a separate file.

Signed-off-by: Eric Blake <eblake@redhat.com>
Reviewed-by: Daniel P. Berrangé <berrange@redhat.com>
2019-07-24 17:03:34 -05:00
..
EVENTHANDLERS.txt qemu/doc: Fix function name for handling events 2017-06-13 09:43:42 +02:00
libvirtd_qemu.aug qemu: Add support for overriding max threads per process limit 2019-07-24 15:59:49 -06:00
Makefile.inc.am qemu: Move qemuParseKeywords(Free) to the monitor code 2019-06-20 12:15:05 +02:00
MIGRATION.txt doc: fix writing of QEMU 2017-03-08 17:33:07 +01:00
qemu_agent.c util: Move enum convertors into virenum.(c|h) 2019-04-10 09:12:04 +02:00
qemu_agent.h src/qemu: use #pragma once in headers 2019-06-19 17:12:30 +02:00
qemu_alias.c Remove all Author(s): lines from source file headers 2018-12-13 16:08:38 +00:00
qemu_alias.h src/qemu: use #pragma once in headers 2019-06-19 17:12:30 +02:00
qemu_block.c qemu: block: Add generator for creating storage with blockdev-create 2019-07-18 17:59:34 +02:00
qemu_block.h qemu: block: Add generator for creating storage with blockdev-create 2019-07-18 17:59:34 +02:00
qemu_blockjob.c qemu: blockjob: Unplug inherited storage chains when concluding blockjob 2019-07-18 17:59:34 +02:00
qemu_blockjob.h qemu: blockjob: Adjust ATTRIBUTE_NONNULL statements for qemuBlockJobDiskNew 2019-07-19 08:47:39 +02:00
qemu_capabilities.c qemu: Add bochs-display capability 2019-07-15 10:21:21 +02:00
qemu_capabilities.h qemu: Add bochs-display capability 2019-07-15 10:21:21 +02:00
qemu_capspriv.h qemu: Translate feature names from query-cpu-model-expansion 2019-06-20 00:22:39 +02:00
qemu_cgroup.c qemu: Add support for overriding max threads per process limit 2019-07-24 15:59:49 -06:00
qemu_cgroup.h src/qemu: use #pragma once in headers 2019-06-19 17:12:30 +02:00
qemu_command.c qemu: block: Use 'auto-read-only' instead of 'read-only' for backing chain 2019-07-18 17:59:34 +02:00
qemu_command.h qemu: Introduce new set of helpers for attaching and detaching storage chains 2019-06-26 08:59:37 +02:00
qemu_conf.c qemu: Add support for overriding max threads per process limit 2019-07-24 15:59:49 -06:00
qemu_conf.h qemu: Add support for overriding max threads per process limit 2019-07-24 15:59:49 -06:00
qemu_domain_address.c qemu: address: remove useless comment 2019-07-16 17:00:36 +02:00
qemu_domain_address.h src/qemu: use #pragma once in headers 2019-06-19 17:12:30 +02:00
qemu_domain.c qemu: Detect managed persistent reservations in block job orphan chains 2019-07-18 17:59:34 +02:00
qemu_domain.h qemu: Detect managed persistent reservations in block job orphan chains 2019-07-18 17:59:34 +02:00
qemu_driver.c snapshot: Don't leak moment obj list metaroot to callers 2019-07-24 17:03:34 -05:00
qemu_driver.h src/qemu: use #pragma once in headers 2019-06-19 17:12:30 +02:00
qemu_extdevice.c Require a semicolon for VIR_LOG_INIT calls 2019-02-03 17:46:29 -05:00
qemu_extdevice.h src/qemu: use #pragma once in headers 2019-06-19 17:12:30 +02:00
qemu_firmware.c qemu_firmware: only set nfeatures on success 2019-06-26 09:24:09 +02:00
qemu_firmware.h src/qemu: use #pragma once in headers 2019-06-19 17:12:30 +02:00
qemu_hostdev.c qemu: De-duplicate some path definitions 2019-07-03 09:33:45 +02:00
qemu_hostdev.h src/qemu: use #pragma once in headers 2019-06-19 17:12:30 +02:00
qemu_hotplug.c qemu: hotplug: Transfer ownership of backing chain to block job on disk unplug 2019-07-18 17:59:34 +02:00
qemu_hotplug.h src/qemu: use #pragma once in headers 2019-06-19 17:12:30 +02:00
qemu_hotplugpriv.h src/qemu: use #pragma once in headers 2019-06-19 17:12:30 +02:00
qemu_interface.c Revert "virt drivers: don't handle type=network after resolving actual network type" 2019-04-30 14:42:22 +01:00
qemu_interface.h src/qemu: use #pragma once in headers 2019-06-19 17:12:30 +02:00
qemu_migration_cookie.c qemu: Use VIR_XPATH_NODE_AUTORESTORE when XPath context is modified 2019-03-04 13:04:20 +01:00
qemu_migration_cookie.h src/qemu: use #pragma once in headers 2019-06-19 17:12:30 +02:00
qemu_migration_params.c Always put _LAST enums on second line of VIR_ENUM_IMPL 2019-04-11 12:47:23 -04:00
qemu_migration_params.h src/qemu: use #pragma once in headers 2019-06-19 17:12:30 +02:00
qemu_migration_paramspriv.h src/qemu: use #pragma once in headers 2019-06-19 17:12:30 +02:00
qemu_migration.c qemu: blockjob: Save status XML when modifying job state 2019-07-18 17:59:34 +02:00
qemu_migration.h src/qemu: use #pragma once in headers 2019-06-19 17:12:30 +02:00
qemu_monitor_json.c qemu: Remove unnecessary check in qemuMonitorJSONGetJobInfoOne 2019-07-23 10:55:56 -04:00
qemu_monitor_json.h qemu: monitor: Add APIs for 'blockdev-create' 2019-07-18 17:59:33 +02:00
qemu_monitor_priv.h src/qemu: use #pragma once in headers 2019-06-19 17:12:30 +02:00
qemu_monitor_text.c qemu: Remove qemuMonitorTextSetCPU 2019-06-20 15:59:19 +02:00
qemu_monitor_text.h qemu: Remove qemuMonitorTextSetCPU 2019-06-20 15:59:19 +02:00
qemu_monitor.c qemu: monitor: Add APIs for 'blockdev-create' 2019-07-18 17:59:33 +02:00
qemu_monitor.h qemu: monitor: Add APIs for 'blockdev-create' 2019-07-18 17:59:33 +02:00
qemu_process.c qemu: process: Don't use qemuBlockJobStartupFinalize in qemuProcessHandleBlockJob 2019-07-19 15:49:40 +02:00
qemu_process.h qemu: also delete qemuProcessAttach 2019-06-20 12:47:10 +02:00
qemu_processpriv.h src/qemu: use #pragma once in headers 2019-06-19 17:12:30 +02:00
qemu_qapi.c qemu: qapi: Implement support for 'features' 2019-06-20 09:20:04 +02:00
qemu_qapi.h src/qemu: use #pragma once in headers 2019-06-19 17:12:30 +02:00
qemu_security.c qemu_security: Implement qemuSecurityMoveImageMetadata 2019-07-03 08:36:04 +02:00
qemu_security.h qemu_security: Implement qemuSecurityMoveImageMetadata 2019-07-03 08:36:04 +02:00
qemu_tpm.c tpm: minor argument comment fix 2019-06-26 09:24:09 +02:00
qemu_tpm.h src/qemu: use #pragma once in headers 2019-06-19 17:12:30 +02:00
qemu.conf qemu: Add support for overriding max threads per process limit 2019-07-24 15:59:49 -06:00
test_libvirtd_qemu.aug.in qemu: Add support for overriding max threads per process limit 2019-07-24 15:59:49 -06:00
THREADS.txt qemu: Introduce APIs for manipulating qemuDomainAgentJob 2018-06-20 13:24:17 +02:00