]> git.ipfire.org Git - thirdparty/libvirt.git/commit
Remove more useless if tests before "free"-like functions.
authorJim Meyering <meyering@redhat.com>
Thu, 7 Feb 2008 16:49:29 +0000 (16:49 +0000)
committerJim Meyering <meyering@redhat.com>
Thu, 7 Feb 2008 16:49:29 +0000 (16:49 +0000)
commite8ff93b4e6c2e64cc37d5d568497f0d6c92d237b
treebece93d50e4163c155b36f0a3439c5eb9d3a8aec
parent5a932141435d60ad5a2e23fef3294bcba93b2235
Remove more useless if tests before "free"-like functions.

* build-aux/useless-if-before-free: Rename from ...
* build-aux/find-unnecessary-if-before-free: ... this.  Remove file.
Also changed it so that new names are no longer hard-coded in the
script.  Instead, they're supplied via options:
* Makefile.cfg (useless_free_options): Define.
Add xmlXPathFreeObject to the list of free-like functions it detects.
* Makefile.maint (sc_avoid_if_before_free): Reflect script renaming.
* .x-sc_avoid_if_before_free: Likewise.
* src/openvz_conf.c (openvzParseXML): Remove useless "if"-before-free.
* src/qemu_conf.c (qemudParseXML, qemudParseNetworkXML): Likewise.
* src/virsh.c (cmdVNCDisplay, cmdTTYConsole, cmdDetachInterface):
(cmdDetachDisk): Likewise.
* src/xm_internal.c (xenXMConfigSetIntFromXPath): Likewise.
(xenXMConfigSetStringFromXPath, xenXMParseXMLToConfig): Likewise.
(xenXMDomainAttachDevice, xenXMAttachDisk, xenXMAttachInterface):
(xenXMDomainDetachDevice): Likewise.
* src/xml.c (virXPathString): Likewise.
* tests/xmlrpctest.c (checkRequestValue): Likewise.
12 files changed:
.x-sc_avoid_if_before_free
ChangeLog
Makefile.cfg
Makefile.maint
build-aux/find-unnecessary-if-before-free [deleted file]
build-aux/useless-if-before-free [new file with mode: 0755]
src/openvz_conf.c
src/qemu_conf.c
src/virsh.c
src/xm_internal.c
src/xml.c
tests/xmlrpctest.c