libvirt/src/qemu
Eric Blake fcbeb2e9d1 blockjob: add new monitor json conversions
The previous patch hoisted some bounds checks to the callers;
but someone that is not aware of the hoisted check could now
try passing an integer between LLONG_MAX and ULLONG_MAX.  As a
safety measure, add new json conversion modes that let libvirt
error out early instead of pass bad numbers to qemu, if the
caller ever makes a mistake due to later refactoring.

Convert the various blockjob QMP calls to use the new modes,
and switch some of them to be optional (QMP has always supported
an omitted "speed" the same as "speed":0, for everything except
block-job-set-speed).

* src/qemu/qemu_monitor_json.c (qemuMonitorJSONMakeCommandRaw):
Add 'j'/'y' and 'J'/'Y' to error out on negative input.
(qemuMonitorJSONDriveMirror, qemuMonitorJSONBlockCommit)
(qemuMonitorJSONBlockJob): Use it.

Signed-off-by: Eric Blake <eblake@redhat.com>
2014-09-05 10:48:45 -06:00
..
libvirtd_qemu.aug migration: add support for migrateURI configuration 2014-05-20 13:13:29 +02:00
MIGRATION.txt qemu: Implement migration job phases 2011-07-27 08:45:09 -06:00
qemu_agent.c qemu_agent: Resolve Coverity RESOURCE_LEAK 2014-08-28 08:12:16 -04:00
qemu_agent.h qemu: Implement virDomain{Get,Set}Time 2014-05-15 16:44:45 +02:00
qemu_capabilities.c maint: use consistent if-else braces in qemu 2014-09-04 08:53:21 -06:00
qemu_capabilities.h qemu: Add support for iothreads 2014-08-28 16:27:53 -04:00
qemu_cgroup.c conf: RNG: Always fill in default random source path for default backend 2014-07-28 10:07:09 +02:00
qemu_cgroup.h qemu: leave restricting cpuset.mems after initialization 2014-07-16 20:15:46 +02:00
qemu_command.c maint: use consistent if-else braces in qemu 2014-09-04 08:53:21 -06:00
qemu_command.h Perform disk config validity checking for attach-device config 2014-08-21 07:06:35 -04:00
qemu_conf.c Fix spacing around commas 2014-08-22 15:03:39 +02:00
qemu_conf.h qemu: hotplug: Sanitize shared device removal on media change 2014-08-20 09:28:05 +02:00
qemu_domain.c qemu: Tidy up job handling during live migration 2014-08-14 12:12:42 +02:00
qemu_domain.h qemu: Tidy up job handling during live migration 2014-08-14 12:12:42 +02:00
qemu_driver.c blockjob: hoist bandwidth scaling out of monitor code 2014-09-05 10:42:07 -06:00
qemu_driver.h Change file names in comments to match the files they are in 2014-03-10 14:26:04 +01:00
qemu_hostdev.c drivers: use virDirRead API 2014-04-28 17:52:45 -06:00
qemu_hostdev.h Capitalize USB, PCI and SCSI in hostdev methods 2014-03-12 16:20:01 +00:00
qemu_hotplug.c maint: use consistent if-else braces in qemu 2014-09-04 08:53:21 -06:00
qemu_hotplug.h qemu: hotplug: Format proper source string for cdrom media change 2014-08-20 09:28:04 +02:00
qemu_hotplugpriv.h qemu: Let tests override waiting time for device unplug 2013-08-26 16:09:55 +02:00
qemu_migration.c blockjob: split out block info monitor handling 2014-09-05 10:37:08 -06:00
qemu_migration.h qemu: enum cleanups in "src/qemu/*" 2014-06-24 12:56:54 -06:00
qemu_monitor_json.c blockjob: add new monitor json conversions 2014-09-05 10:48:45 -06:00
qemu_monitor_json.h blockjob: split out block info monitor handling 2014-09-05 10:37:08 -06:00
qemu_monitor_text.c maint: use consistent if-else braces in qemu 2014-09-04 08:53:21 -06:00
qemu_monitor_text.h conf: more enum cleanups in "src/conf/domain_conf.h" 2014-06-02 15:32:58 -06:00
qemu_monitor.c blockjob: hoist bandwidth scaling out of monitor code 2014-09-05 10:42:07 -06:00
qemu_monitor.h blockjob: hoist bandwidth scaling out of monitor code 2014-09-05 10:42:07 -06:00
qemu_process.c maint: use consistent if-else braces in qemu 2014-09-04 08:53:21 -06:00
qemu_process.h qemu: Tidy up job handling during live migration 2014-08-14 12:12:42 +02:00
qemu_processpriv.h qemu: Export qemuProcessHandleDeviceDeleted for tests 2013-08-26 16:09:55 +02:00
qemu.conf qemu: fix comment in qemu.conf 2014-08-04 07:53:55 +02:00
test_libvirtd_qemu.aug.in migration: add support for migrateURI configuration 2014-05-20 13:13:29 +02:00
THREADS.txt Remove qemuDriverLock from almost everywhere 2013-02-13 11:10:30 +00:00