]> xenbits.xensource.com Git - libvirt.git/commit
maint: simplify lots of libxml2 clients
authorEric Blake <eblake@redhat.com>
Thu, 18 Aug 2011 21:37:14 +0000 (15:37 -0600)
committerEric Blake <eblake@redhat.com>
Fri, 19 Aug 2011 15:13:55 +0000 (09:13 -0600)
commitd89dd42d51679cd73932f8dc9472549bb1265ac4
treec99271bbb4d5caf92809167853863fa89ab51b86
parent751304e367cdf301dd1feb21b5a655dcecbf06a4
maint: simplify lots of libxml2 clients

Repetitive patterns should be factored.  The sign of a good
factorization is a change that kills 5x more lines than it adds :)

* src/conf/domain_conf.c (virDomainDeviceDefParse)
(virDomainSnapshotDefParseString): Use new convenience macros.
* src/conf/storage_conf.c (virStoragePoolDefParseSourceString):
Likewise.
* src/cpu/cpu.c (cpuCompareXML, cpuBaselineXML): Likewise.
* src/esx/esx_vi.c (esxVI_Context_Execute): Likewise.
* src/qemu/qemu_migration.c (qemuMigrationCookieXMLParseStr):
Likewise.
* src/security/virt-aa-helper.c (caps_mockup): Likewise.
* src/test/test_driver.c (testOpenFromFile): Likewise.
* tests/cputest.c (cpuTestLoadXML, cpuTestLoadMultiXML):
Likewise.
* tools/virsh.c (cmdFreecell, makeCloneXML, cmdVNCDisplay)
(cmdTTYConsole, cmdDetachInterface, cmdDetachDisk)
(cmdSnapshotCreate, cmdSnapshotCreateAs, cmdSnapshotCurrent)
(cmdSnapshotList, cmdSnapshotParent): Likewise.
src/conf/domain_conf.c
src/conf/storage_conf.c
src/cpu/cpu.c
src/esx/esx_vi.c
src/qemu/qemu_migration.c
src/security/virt-aa-helper.c
src/test/test_driver.c
tests/cputest.c
tools/virsh.c