]> git.ipfire.org Git - thirdparty/libvirt.git/commitdiff
virutil: Move string related functions to virstring.c
authorMichal Privoznik <mprivozn@redhat.com>
Wed, 3 Apr 2013 10:36:23 +0000 (12:36 +0200)
committerMichal Privoznik <mprivozn@redhat.com>
Thu, 2 May 2013 14:56:55 +0000 (16:56 +0200)
The source code base needs to be adapted as well. Some files
include virutil.h just for the string related functions (here,
the include is substituted to match the new file), some include
virutil.h without any need (here, the include is removed), and
some require both.

242 files changed:
cfg.mk
daemon/libvirtd-config.c
daemon/libvirtd.c
daemon/remote.c
python/libvirt-override.c
src/conf/capabilities.c
src/conf/cpu_conf.c
src/conf/device_conf.c
src/conf/domain_audit.c
src/conf/domain_conf.c
src/conf/domain_conf.h
src/conf/interface_conf.c
src/conf/netdev_bandwidth_conf.c
src/conf/netdev_vport_profile_conf.c
src/conf/network_conf.c
src/conf/node_device_conf.c
src/conf/nwfilter_conf.c
src/conf/nwfilter_conf.h
src/conf/nwfilter_params.c
src/conf/secret_conf.c
src/conf/snapshot_conf.c
src/conf/storage_conf.c
src/conf/storage_conf.h
src/conf/storage_encryption_conf.c
src/conf/virchrdev.c
src/cpu/cpu_powerpc.c
src/cpu/cpu_x86.c
src/datatypes.c
src/driver.c
src/esx/esx_device_monitor.c
src/esx/esx_driver.c
src/esx/esx_interface_driver.c
src/esx/esx_network_driver.c
src/esx/esx_nwfilter_driver.c
src/esx/esx_secret_driver.c
src/esx/esx_storage_backend_iscsi.c
src/esx/esx_storage_backend_vmfs.c
src/esx/esx_util.c
src/esx/esx_vi.c
src/esx/esx_vi_types.c
src/fdstream.c
src/hyperv/hyperv_device_monitor.c
src/hyperv/hyperv_driver.c
src/hyperv/hyperv_interface_driver.c
src/hyperv/hyperv_network_driver.c
src/hyperv/hyperv_nwfilter_driver.c
src/hyperv/hyperv_secret_driver.c
src/hyperv/hyperv_storage_driver.c
src/hyperv/hyperv_util.c
src/hyperv/hyperv_wmi.c
src/interface/interface_backend_udev.c
src/libvirt.c
src/libvirt_private.syms
src/libxl/libxl_driver.c
src/locking/lock_daemon.c
src/locking/lock_daemon_config.c
src/locking/lock_daemon_dispatch.c
src/locking/lock_driver_lockd.c
src/locking/lock_driver_sanlock.c
src/locking/lock_manager.c
src/lxc/lxc_cgroup.c
src/lxc/lxc_container.c
src/lxc/lxc_controller.c
src/lxc/lxc_driver.c
src/lxc/lxc_fuse.c
src/lxc/lxc_fuse.h
src/lxc/lxc_monitor.c
src/lxc/lxc_process.c
src/network/bridge_driver.c
src/node_device/node_device_driver.c
src/node_device/node_device_linux_sysfs.c
src/node_device/node_device_udev.c
src/nodeinfo.c
src/nwfilter/nwfilter_dhcpsnoop.c
src/nwfilter/nwfilter_driver.c
src/nwfilter/nwfilter_ebiptables_driver.c
src/nwfilter/nwfilter_learnipaddr.c
src/openvz/openvz_conf.c
src/openvz/openvz_driver.c
src/parallels/parallels_driver.c
src/parallels/parallels_network.c
src/parallels/parallels_storage.c
src/parallels/parallels_utils.c
src/phyp/phyp_driver.c
src/qemu/qemu_agent.c
src/qemu/qemu_bridge_filter.c
src/qemu/qemu_capabilities.c
src/qemu/qemu_cgroup.c
src/qemu/qemu_command.c
src/qemu/qemu_conf.c
src/qemu/qemu_domain.c
src/qemu/qemu_driver.c
src/qemu/qemu_hotplug.c
src/qemu/qemu_migration.c
src/qemu/qemu_monitor.c
src/qemu/qemu_monitor_text.c
src/qemu/qemu_process.c
src/remote/remote_driver.c
src/rpc/virkeepalive.c
src/rpc/virnetserverclient.c
src/rpc/virnetsocket.c
src/rpc/virnetsshsession.c
src/rpc/virnettlscontext.c
src/secret/secret_driver.c
src/security/security_apparmor.c
src/security/security_dac.c
src/security/security_selinux.c
src/security/virt-aa-helper.c
src/storage/storage_backend.c
src/storage/storage_backend_disk.c
src/storage/storage_backend_fs.c
src/storage/storage_backend_iscsi.c
src/storage/storage_backend_logical.c
src/storage/storage_backend_mpath.c
src/storage/storage_backend_rbd.c
src/storage/storage_backend_scsi.c
src/storage/storage_backend_sheepdog.c
src/storage/storage_driver.c
src/test/test_driver.c
src/uml/uml_conf.c
src/uml/uml_driver.c
src/util/iohelper.c
src/util/viraudit.c
src/util/virauth.c
src/util/virauthconfig.c
src/util/virbitmap.c
src/util/vircommand.c
src/util/vircommand.h
src/util/virdnsmasq.c
src/util/virebtables.c
src/util/virerror.c
src/util/virfile.c
src/util/virhook.h
src/util/virinitctl.c
src/util/viriptables.c
src/util/virjson.c
src/util/virlockspace.c
src/util/virlog.c
src/util/virnetdev.c
src/util/virnetdevbandwidth.c
src/util/virnetdevbridge.c
src/util/virnetdevmacvlan.c
src/util/virnetdevopenvswitch.c
src/util/virnetdevopenvswitch.h
src/util/virnetdevtap.c
src/util/virnetdevveth.c
src/util/virnetdevvportprofile.c
src/util/virpci.c
src/util/virpidfile.c
src/util/virprocess.c
src/util/virrandom.c
src/util/virsexpr.c
src/util/virsocketaddr.c
src/util/virstatslinux.c
src/util/virstoragefile.c
src/util/virstring.c
src/util/virstring.h
src/util/virsysinfo.c
src/util/virtime.c
src/util/virtpm.c
src/util/virtypedparam.c
src/util/viruri.c
src/util/virusb.c
src/util/virutil.c
src/util/virutil.h
src/util/virxml.c
src/vbox/vbox_MSCOMGlue.c
src/vbox/vbox_XPCOMCGlue.c
src/vbox/vbox_driver.c
src/vbox/vbox_tmpl.c
src/vmware/vmware_conf.c
src/vmware/vmware_driver.c
src/vmx/vmx.c
src/xen/block_stats.c
src/xen/xen_driver.c
src/xen/xen_hypervisor.c
src/xen/xend_internal.c
src/xen/xm_internal.c
src/xenapi/xenapi_driver.c
src/xenapi/xenapi_utils.c
src/xenxs/xen_sxpr.c
src/xenxs/xen_xm.c
tests/commandtest.c
tests/cputest.c
tests/domainsnapshotxml2xmltest.c
tests/esxutilstest.c
tests/interfacexml2xmltest.c
tests/libvirtdconftest.c
tests/lxcxml2xmltest.c
tests/networkxml2conftest.c
tests/networkxml2xmltest.c
tests/nodedevxml2xmltest.c
tests/nodeinfotest.c
tests/nwfilterxml2xmltest.c
tests/openvzutilstest.c
tests/qemuargv2xmltest.c
tests/qemuhelptest.c
tests/qemumonitortest.c
tests/qemumonitortestutils.c
tests/qemuxml2argvtest.c
tests/qemuxml2xmltest.c
tests/qemuxmlnstest.c
tests/securityselinuxlabeltest.c
tests/securityselinuxtest.c
tests/sexpr2xmltest.c
tests/storagepoolxml2xmltest.c
tests/storagevolxml2argvtest.c
tests/storagevolxml2xmltest.c
tests/sysinfotest.c
tests/testutils.c
tests/virauthconfigtest.c
tests/virbuftest.c
tests/vircgrouptest.c
tests/virdrivermoduletest.c
tests/virhashtest.c
tests/viridentitytest.c
tests/virkeyfiletest.c
tests/virnetmessagetest.c
tests/virnetsockettest.c
tests/virportallocatortest.c
tests/virshtest.c
tests/virstoragetest.c
tests/virstringtest.c
tests/virtimetest.c
tests/viruritest.c
tests/vmx2xmltest.c
tests/xencapstest.c
tests/xmconfigtest.c
tests/xml2sexprtest.c
tests/xml2vmxtest.c
tools/console.c
tools/virsh-domain-monitor.c
tools/virsh-domain.c
tools/virsh-host.c
tools/virsh-interface.c
tools/virsh-network.c
tools/virsh-nodedev.c
tools/virsh-pool.c
tools/virsh-snapshot.c
tools/virsh-volume.c
tools/virsh.c
tools/virt-host-validate-common.c

diff --git a/cfg.mk b/cfg.mk
index f0f78f5f2d002141062a5f43cad063d049187857..d499dede191ceb9528879036f4b8437ec914409d 100644 (file)
--- a/cfg.mk
+++ b/cfg.mk
@@ -858,7 +858,7 @@ exclude_file_name_regexp--sc_prohibit_always_true_header_tests = \
   ^python/(libvirt-(lxc-|qemu-)?override|typewrappers)\.c$$
 
 exclude_file_name_regexp--sc_prohibit_asprintf = \
-  ^(bootstrap.conf$$|src/util/virutil\.c$$|examples/domain-events/events-c/event-test\.c$$|tests/vircgroupmock\.c$$)
+  ^(bootstrap.conf$$|src/util/virstring\.c$$|examples/domain-events/events-c/event-test\.c$$|tests/vircgroupmock\.c$$)
 
 exclude_file_name_regexp--sc_prohibit_close = \
   (\.p[yl]$$|^docs/|^(src/util/virfile\.c|src/libvirt\.c|tests/vircgroupmock\.c)$$)
@@ -892,7 +892,7 @@ exclude_file_name_regexp--sc_prohibit_setuid = ^src/util/virutil\.c$$
 exclude_file_name_regexp--sc_prohibit_sprintf = \
   ^(docs/hacking\.html\.in)|(examples/systemtap/.*stp)|(src/dtrace2systemtap\.pl)|(src/rpc/gensystemtap\.pl)$$
 
-exclude_file_name_regexp--sc_prohibit_strncpy = ^src/util/virutil\.c$$
+exclude_file_name_regexp--sc_prohibit_strncpy = ^src/util/virstring\.c$$
 
 exclude_file_name_regexp--sc_prohibit_strtol = \
   ^src/(util/virsexpr|(vbox|xen|xenxs)/.*)\.c$$
index 5e3ae218f33ff707d0257b86f747f13594c7423b..efb564eeb3541fcdc98a207638fbc614897aab63 100644 (file)
@@ -32,6 +32,8 @@
 #include "configmake.h"
 #include "remote/remote_protocol.h"
 #include "remote/remote_driver.h"
+#include "virstring.h"
+#include "virutil.h"
 
 #define VIR_FROM_THIS VIR_FROM_CONF
 
index 38b7346698093a91a4bb3a0804af6cb2a95cfd7e..9f81a0f1ea9d96b0daef207bf23471a898bb2639 100644 (file)
@@ -43,7 +43,6 @@
 #include "libvirtd.h"
 #include "libvirtd-config.h"
 
-#include "virutil.h"
 #include "viruuid.h"
 #include "remote_driver.h"
 #include "viralloc.h"
@@ -54,6 +53,7 @@
 #include "virhook.h"
 #include "viraudit.h"
 #include "locking/lock_manager.h"
+#include "virstring.h"
 
 #ifdef WITH_DRIVER_MODULES
 # include "driver.h"
index e5e3f2ca5db329deacb064d4c30c827878ae19e0..8c796807219daf1fcd1649f2501149925237b839 100644 (file)
@@ -35,7 +35,6 @@
 #include "datatypes.h"
 #include "viralloc.h"
 #include "virlog.h"
-#include "virutil.h"
 #include "stream.h"
 #include "viruuid.h"
 #include "vircommand.h"
@@ -49,7 +48,7 @@
 #include "remote_protocol.h"
 #include "qemu_protocol.h"
 #include "lxc_protocol.h"
-
+#include "virstring.h"
 
 #define VIR_FROM_THIS VIR_FROM_RPC
 
index 244b7ec5e51e55ce6ebb26f4a122dbdff8d3394d..856789a2acf21944a0cef634cc020592cfe3d944 100644 (file)
@@ -28,6 +28,7 @@
 #include "virtypedparam.h"
 #include "ignore-value.h"
 #include "virutil.h"
+#include "virstring.h"
 
 #ifndef __CYGWIN__
 extern void initlibvirtmod(void);
index c7ec92f22a73686d3b2986f3d74e6fb5e9d60a0f..5340b63af019747cf2e8b6a4776c4971b331f307 100644 (file)
@@ -28,7 +28,6 @@
 #include "capabilities.h"
 #include "virbuffer.h"
 #include "viralloc.h"
-#include "virutil.h"
 #include "viruuid.h"
 #include "cpu_conf.h"
 #include "virerror.h"
index bdc5f1d17ea6162f59a103dcbbf0c9d19ba41af4..6aaee75ad7ed3639e88e7c2a6efa90a712e92450 100644 (file)
 
 #include "virerror.h"
 #include "viralloc.h"
-#include "virutil.h"
 #include "virbuffer.h"
 #include "cpu_conf.h"
 #include "domain_conf.h"
+#include "virstring.h"
 
 #define VIR_FROM_THIS VIR_FROM_CPU
 
index 099b1cbc4d57ce993469b0d940e7c03ce35f77a2..f49dc21d84f6cc4ea15ff999fbf1078450888b4a 100644 (file)
@@ -26,9 +26,9 @@
 #include "viralloc.h"
 #include "virxml.h"
 #include "viruuid.h"
-#include "virutil.h"
 #include "virbuffer.h"
 #include "device_conf.h"
+#include "virstring.h"
 
 #define VIR_FROM_THIS VIR_FROM_DEVICE
 
index d81744c0fc828a56a0d88154e098aab060f9590d..40910d679f0c2d8450393cbc1991f3f0d451c554 100644 (file)
@@ -31,6 +31,7 @@
 #include "viruuid.h"
 #include "virlog.h"
 #include "viralloc.h"
+#include "virstring.h"
 
 /* Return nn:mm in hex for block and character devices, and NULL
  * for other file types, stat failure, or allocation failure.  */
index 608870f1575d4e1cf2fd14216678a4011c01803b..fe97c02fc5e228c0e0e7df4f8e24212aac18da72 100644 (file)
@@ -38,7 +38,6 @@
 #include "verify.h"
 #include "virxml.h"
 #include "viruuid.h"
-#include "virutil.h"
 #include "virbuffer.h"
 #include "virlog.h"
 #include "nwfilter_conf.h"
@@ -52,6 +51,7 @@
 #include "netdev_vlan_conf.h"
 #include "device_conf.h"
 #include "virtpm.h"
+#include "virstring.h"
 
 #define VIR_FROM_THIS VIR_FROM_DOMAIN
 
index 3a0f23ae7eaa634cb5d16bd616ae5ec4def9c8a9..21f7ce28da7583bef4ed5c9a011aa0757ebe6b5e 100644 (file)
@@ -32,7 +32,6 @@
 # include "capabilities.h"
 # include "storage_encryption_conf.h"
 # include "cpu_conf.h"
-# include "virutil.h"
 # include "virthread.h"
 # include "virhash.h"
 # include "virsocketaddr.h"
index 7ca9c8618c277417c4b301eb9b68cee7763bc8ce..fd3c2920f61996a4205420810dfdccc70321adbd 100644 (file)
@@ -30,7 +30,6 @@
 #include "viralloc.h"
 #include "virxml.h"
 #include "viruuid.h"
-#include "virutil.h"
 #include "virbuffer.h"
 
 #define VIR_FROM_THIS VIR_FROM_INTERFACE
index b830cd00cbf7e151ba4056a8ca7487fc06ff4890..87249cb236cd7e3bec7a4aaaeb59af41178bfad6 100644 (file)
@@ -24,9 +24,9 @@
 
 #include "netdev_bandwidth_conf.h"
 #include "virerror.h"
-#include "virutil.h"
 #include "viralloc.h"
 #include "domain_conf.h"
+#include "virstring.h"
 
 #define VIR_FROM_THIS VIR_FROM_NONE
 
index 47f51f95923ed44a41888017be29a84003bd3ca4..c2753394d4b52e04a834781aed04a3f290c534a4 100644 (file)
@@ -25,6 +25,7 @@
 #include "netdev_vport_profile_conf.h"
 #include "virerror.h"
 #include "viralloc.h"
+#include "virstring.h"
 
 #define VIR_FROM_THIS VIR_FROM_NONE
 
index d910a279feaeb6529262a8301e7ded1d0f527a2a..8abfa53008e63563467ac8cfc77f391aa3d6dcf1 100644 (file)
 #include "viralloc.h"
 #include "virxml.h"
 #include "viruuid.h"
-#include "virutil.h"
 #include "virbuffer.h"
 #include "c-ctype.h"
 #include "virfile.h"
+#include "virstring.h"
 
 #define MAX_BRIDGE_ID 256
 #define VIR_FROM_THIS VIR_FROM_NETWORK
index 8fe4e0350d88c8dff4241db86083a0414dcbd4e0..f9303c1ae4f6c15e4d36be3e58312233a8b12c15 100644 (file)
@@ -32,7 +32,6 @@
 
 #include "node_device_conf.h"
 #include "virxml.h"
-#include "virutil.h"
 #include "virbuffer.h"
 #include "viruuid.h"
 #include "virrandom.h"
index b61010df69d472f82c91ce4d190af4eb7fd05f2b..08222de68d1615d9ee42bc1ae9dfd27895e2f44f 100644 (file)
@@ -47,7 +47,7 @@
 #include "domain_conf.h"
 #include "c-ctype.h"
 #include "virfile.h"
-
+#include "virstring.h"
 
 #define VIR_FROM_THIS VIR_FROM_NWFILTER
 
index 48998ec7f065821a4893a4f280bc026bdafe23dc..5d04cff8903c810175748990085371285831297d 100644 (file)
@@ -28,7 +28,6 @@
 
 # include "internal.h"
 
-# include "virutil.h"
 # include "virhash.h"
 # include "virxml.h"
 # include "virbuffer.h"
index 7aebc8db0aa3dafb2c8f63fe0ea9af02b6c161d8..2509c0d8e608560769d9da873db5f613e9b48195 100644 (file)
@@ -31,6 +31,7 @@
 #include "nwfilter_params.h"
 #include "domain_conf.h"
 #include "virlog.h"
+#include "virstring.h"
 
 #define VIR_FROM_THIS VIR_FROM_NWFILTER
 
index a81a91b6c959bd73fbb09faa15808d39097647b2..5bcfe12a01bd96c206233534dce6b6db28fcea9f 100644 (file)
@@ -29,7 +29,6 @@
 #include "viralloc.h"
 #include "secret_conf.h"
 #include "virerror.h"
-#include "virutil.h"
 #include "virxml.h"
 #include "viruuid.h"
 
index bd5684d8cbba4378dfcb67c63b5121a0d0ff697a..5b54a28a596aef0bb883dfe12ca5c2f300a48999 100644 (file)
 #include "secret_conf.h"
 #include "snapshot_conf.h"
 #include "virstoragefile.h"
-#include "virutil.h"
 #include "viruuid.h"
 #include "virfile.h"
 #include "virerror.h"
 #include "virxml.h"
+#include "virstring.h"
 
 #define VIR_FROM_THIS VIR_FROM_DOMAIN_SNAPSHOT
 
index b58385d2fda22dcfd85ff61e4130bc97cd39e795..9f2012e22b5f13db7045e3f3d1ac0aa3779ce04b 100644 (file)
@@ -41,9 +41,9 @@
 #include "virxml.h"
 #include "viruuid.h"
 #include "virbuffer.h"
-#include "virutil.h"
 #include "viralloc.h"
 #include "virfile.h"
+#include "virstring.h"
 
 #define VIR_FROM_THIS VIR_FROM_STORAGE
 
index 60b8034a75fd3f98690c3d51d4533be7b6ead5cc..567a4ac3d1976049ec71539d0bff6857b79a6b3d 100644 (file)
@@ -25,7 +25,6 @@
 # define __VIR_STORAGE_CONF_H__
 
 # include "internal.h"
-# include "virutil.h"
 # include "storage_encryption_conf.h"
 # include "virthread.h"
 
index 88dff1b2104d213b76d1ae762c74154a347ce095..c710bbd2485350c37da7eefd6190d23bb564b437 100644 (file)
@@ -31,7 +31,6 @@
 #include "viralloc.h"
 #include "storage_conf.h"
 #include "storage_encryption_conf.h"
-#include "virutil.h"
 #include "virxml.h"
 #include "virerror.h"
 #include "viruuid.h"
index 1802324a772bba8e729946ec783a4f944254a339..025d4a817b7230c49ed032852087349bdf919fbe 100644 (file)
@@ -37,6 +37,7 @@
 #include "virlog.h"
 #include "virerror.h"
 #include "virfile.h"
+#include "virstring.h"
 
 #define VIR_FROM_THIS VIR_FROM_NONE
 
index 5f392ee00749486dc5383b14449bd737e0b9e4e9..b253db278f8c33c3e558982221467cd820454461 100644 (file)
@@ -28,7 +28,6 @@
 
 #include "virlog.h"
 #include "viralloc.h"
-#include "virutil.h"
 #include "cpu.h"
 
 #include "cpu_map.h"
index 4940c23703982bcde0d31e1d53450c0c27d7d20e..14d525e53756b2ca4485789b29c55b32647a78db 100644 (file)
 
 #include "virlog.h"
 #include "viralloc.h"
-#include "virutil.h"
 #include "cpu.h"
 #include "cpu_map.h"
 #include "cpu_x86.h"
 #include "virbuffer.h"
 #include "virendian.h"
-
+#include "virstring.h"
 
 #define VIR_FROM_THIS VIR_FROM_CPU
 
index 0e1dbb17be663cf313323153ec9833357bed3526..d3cf5f2d381b56346ce4e962bccca15d86a80c2e 100644 (file)
@@ -27,7 +27,6 @@
 #include "virlog.h"
 #include "viralloc.h"
 #include "viruuid.h"
-#include "virutil.h"
 
 #define VIR_FROM_THIS VIR_FROM_NONE
 
index 0a5fe0547b1953b936fe6460c05096c2d5c0a253..c35fcd2de2ba81702f21574a68480d27be07e8bc 100644 (file)
@@ -27,8 +27,8 @@
 #include "driver.h"
 #include "viralloc.h"
 #include "virlog.h"
-#include "virutil.h"
 #include "configmake.h"
+#include "virstring.h"
 
 #define DEFAULT_DRIVER_DIR LIBDIR "/libvirt/connection-driver"
 
index 0f3421c8a668bb7aa815ac8aabf10034cd282672..7dc0618cd2f5eabb7fa0dc5adf4de3a1f66bbad8 100644 (file)
@@ -25,7 +25,6 @@
 #include <config.h>
 
 #include "internal.h"
-#include "virutil.h"
 #include "viralloc.h"
 #include "virlog.h"
 #include "viruuid.h"
index 50ff7238261ee42ff1891b025709c756f609597f..dcf64b85c69e3d6292bf2c7cc8e6a9f2f32b44a0 100644 (file)
@@ -28,7 +28,6 @@
 #include "domain_conf.h"
 #include "snapshot_conf.h"
 #include "virauth.h"
-#include "virutil.h"
 #include "viralloc.h"
 #include "virlog.h"
 #include "viruuid.h"
@@ -46,6 +45,7 @@
 #include "esx_vi_methods.h"
 #include "esx_util.h"
 #include "viruri.h"
+#include "virstring.h"
 
 #define VIR_FROM_THIS VIR_FROM_ESX
 
index 44055a1bd1c960c815683c58368f14bc3d3a7477..fe5194c36a7d566bcc926f16f7557c3d273e5578 100644 (file)
@@ -25,7 +25,6 @@
 #include <config.h>
 
 #include "internal.h"
-#include "virutil.h"
 #include "viralloc.h"
 #include "virlog.h"
 #include "viruuid.h"
index c5be2083cc1e629e42f34291369bd9885b60e779..fd57b611c05cb03d1f45992b9b7a0af5442d0575 100644 (file)
@@ -26,7 +26,6 @@
 
 #include "md5.h"
 #include "internal.h"
-#include "virutil.h"
 #include "viralloc.h"
 #include "virlog.h"
 #include "viruuid.h"
index 03b74174db73beff3003f17f2bcb6898613ad741..3b932de1c42426d6b08f152b91c24da96ac015a6 100644 (file)
@@ -25,7 +25,6 @@
 #include <config.h>
 
 #include "internal.h"
-#include "virutil.h"
 #include "viralloc.h"
 #include "virlog.h"
 #include "viruuid.h"
index 2e36e15e79aa3dae30b77410386b26f9466b705f..5607a2efb3454a4aa40c24231d7d29007c6e4e91 100644 (file)
@@ -24,7 +24,6 @@
 #include <config.h>
 
 #include "internal.h"
-#include "virutil.h"
 #include "viralloc.h"
 #include "virlog.h"
 #include "viruuid.h"
index a3336a24c0984ae5d8f5a16088374273347ee7cb..941e8002ac54cba6d008380911e3e2f38d746275 100644 (file)
@@ -28,7 +28,6 @@
 
 #include "internal.h"
 #include "md5.h"
-#include "virutil.h"
 #include "viralloc.h"
 #include "virlog.h"
 #include "viruuid.h"
index 329022e8c75f007ffe268a7bf4a27b2acdb19231..dea6716453f4e06ad24d006987ee7a224a87c832 100644 (file)
@@ -31,7 +31,6 @@
 
 #include "internal.h"
 #include "md5.h"
-#include "virutil.h"
 #include "viralloc.h"
 #include "virlog.h"
 #include "viruuid.h"
@@ -42,6 +41,7 @@
 #include "esx_vi.h"
 #include "esx_vi_methods.h"
 #include "esx_util.h"
+#include "virstring.h"
 
 #define VIR_FROM_THIS VIR_FROM_ESX
 
index 4d2019b34d8e0b843ee5a6c4686f49352ba499aa..4566fec90ea7336de092e1d8086ce37e360f7fdc 100644 (file)
 
 #include "internal.h"
 #include "datatypes.h"
-#include "virutil.h"
 #include "viralloc.h"
 #include "virlog.h"
 #include "viruuid.h"
 #include "vmx.h"
 #include "esx_private.h"
 #include "esx_util.h"
+#include "virstring.h"
 
 #define VIR_FROM_THIS VIR_FROM_ESX
 
index d84ce190752ce1ae412b1dfe94eda692a9638243..ee48159f0e7207d3c9ba2dd9e06776400087204f 100644 (file)
 #include "virbuffer.h"
 #include "viralloc.h"
 #include "virlog.h"
-#include "virutil.h"
 #include "viruuid.h"
 #include "vmx.h"
 #include "virxml.h"
 #include "esx_vi.h"
 #include "esx_vi_methods.h"
 #include "esx_util.h"
+#include "virstring.h"
 
 #define VIR_FROM_THIS VIR_FROM_ESX
 
index d1f91ffa2f809bcea7e56bd2e89eb4da1d75dada..7f4030818a71d6d2d3ebd6dd65a3e3f012c38ca6 100644 (file)
@@ -31,9 +31,9 @@
 #include "datatypes.h"
 #include "viralloc.h"
 #include "virlog.h"
-#include "virutil.h"
 #include "esx_vi.h"
 #include "esx_vi_types.h"
+#include "virstring.h"
 
 #define VIR_FROM_THIS VIR_FROM_ESX
 
index 53dde97ccb7969f2ba44ed9aa65e8d9d6f9063c7..6f8ce530af52cdb80ba04b7439d8ca0d19c57ad6 100644 (file)
@@ -40,6 +40,7 @@
 #include "virutil.h"
 #include "virfile.h"
 #include "configmake.h"
+#include "virstring.h"
 
 #define VIR_FROM_THIS VIR_FROM_STREAMS
 
index c362a1239f1d04684cf35165a37d83cf3065485c..83ea72a30335b65ac398de85929728946ad1c720 100644 (file)
@@ -26,7 +26,6 @@
 #include "internal.h"
 #include "virerror.h"
 #include "datatypes.h"
-#include "virutil.h"
 #include "viralloc.h"
 #include "virlog.h"
 #include "viruuid.h"
index 3b381de0202bd2a0f61aac795daae2c4f07634ef..7031fdbb611f2e92c00e8856f5a1d92420782864 100644 (file)
@@ -27,7 +27,6 @@
 #include "datatypes.h"
 #include "domain_conf.h"
 #include "virauth.h"
-#include "virutil.h"
 #include "viralloc.h"
 #include "virlog.h"
 #include "viruuid.h"
@@ -42,6 +41,7 @@
 #include "hyperv_util.h"
 #include "hyperv_wmi.h"
 #include "openwsman.h"
+#include "virstring.h"
 
 #define VIR_FROM_THIS VIR_FROM_HYPERV
 
index 477b661241689b5a85ecaaa9781770c69c94e203..62123a4f3679247f3a80231acd16ab3eea0ae023 100644 (file)
@@ -26,7 +26,6 @@
 #include "internal.h"
 #include "virerror.h"
 #include "datatypes.h"
-#include "virutil.h"
 #include "viralloc.h"
 #include "virlog.h"
 #include "viruuid.h"
index 336d722ad0a7cfccfe7545e8e15daa1457f247c6..e23f53a16c5904a534e3b23909a3116fc6d710ec 100644 (file)
@@ -26,7 +26,6 @@
 #include "internal.h"
 #include "virerror.h"
 #include "datatypes.h"
-#include "virutil.h"
 #include "viralloc.h"
 #include "virlog.h"
 #include "viruuid.h"
index e7489712b0030069d23e61a03847977521705d0f..034323845b01eb0e32a90c8365252052a52dac22 100644 (file)
@@ -26,7 +26,6 @@
 #include "internal.h"
 #include "virerror.h"
 #include "datatypes.h"
-#include "virutil.h"
 #include "viralloc.h"
 #include "virlog.h"
 #include "viruuid.h"
index 09d9b9e2f3072937d709347043a0ac09874dbb07..3f9f8f5188ad17a03ef41dea4d9aaa294e17a536 100644 (file)
@@ -26,7 +26,6 @@
 #include "internal.h"
 #include "virerror.h"
 #include "datatypes.h"
-#include "virutil.h"
 #include "viralloc.h"
 #include "virlog.h"
 #include "viruuid.h"
index b701dc60a139e87f419bf7e699cc5a33f4b7cd2e..5acc4d8fe89a7dc60a1fa592ecc093b496888076 100644 (file)
@@ -26,7 +26,6 @@
 #include "internal.h"
 #include "virerror.h"
 #include "datatypes.h"
-#include "virutil.h"
 #include "viralloc.h"
 #include "virlog.h"
 #include "viruuid.h"
index 9bc5b814cb3700bf63d351e80308c2df8d6f0422..a55b9397a0a3e9f0575c87a19ad8dfd7e20ea75c 100644 (file)
@@ -24,7 +24,6 @@
 
 #include "internal.h"
 #include "datatypes.h"
-#include "virutil.h"
 #include "viralloc.h"
 #include "virlog.h"
 #include "viruuid.h"
index 33ba21f58d17edcf9718944f39fa48ac421fd44f..65fc83dcfe60ccdf15ce7d0f9c638dde38e7b5a5 100644 (file)
 #include "datatypes.h"
 #include "virlog.h"
 #include "viralloc.h"
-#include "virutil.h"
 #include "viruuid.h"
 #include "virbuffer.h"
 #include "hyperv_private.h"
 #include "hyperv_wmi.h"
+#include "virstring.h"
 
 #define WS_SERIALIZER_FREE_MEM_WORKS 0
 
index 79c57eef6f3c73d6fcaa6a977fcd0dc1aec36042..7daad16b8ec34fa8f8fe187bef0b597732a11468 100644 (file)
@@ -30,6 +30,7 @@
 #include "interface_driver.h"
 #include "interface_conf.h"
 #include "viralloc.h"
+#include "virstring.h"
 
 #define VIR_FROM_THIS VIR_FROM_INTERFACE
 
index 2daa0b4ee008e7a771373e813a9c1d853b7cd31f..15b37a3c9f5e649f0275212fa33037033917ca19 100644 (file)
@@ -62,6 +62,7 @@
 #include "virrandom.h"
 #include "viruri.h"
 #include "virthread.h"
+#include "virstring.h"
 
 #ifdef WITH_TEST
 # include "test/test_driver.h"
index a7e1eeb65dcefd3659526f44c3f880b8617911f8..98660dc2b3520d09182bba85e2b1a4d234662049 100644 (file)
@@ -1745,10 +1745,26 @@ virStorageFileResize;
 
 
 # util/virstring.h
+virArgvToString;
+virAsprintf;
+virSkipSpaces;
+virSkipSpacesAndBackslash;
+virSkipSpacesBackwards;
+virStrcpy;
 virStringArrayHasString;
 virStringFreeList;
 virStringJoin;
 virStringSplit;
+virStrncpy;
+virStrToDouble;
+virStrToLong_i;
+virStrToLong_l;
+virStrToLong_ll;
+virStrToLong_ui;
+virStrToLong_ul;
+virStrToLong_ull;
+virTrimSpaces;
+virVasprintf;
 
 
 # util/virsysinfo.h
@@ -1845,8 +1861,6 @@ virUSBDeviceSetUsedBy;
 saferead;
 safewrite;
 safezero;
-virArgvToString;
-virAsprintf;
 virBuildPathInternal;
 virCompareLimitUlong;
 virDirCreate;
@@ -1914,22 +1928,8 @@ virSetInherit;
 virSetNonBlock;
 virSetUIDGID;
 virSetUIDGIDWithCaps;
-virSkipSpaces;
-virSkipSpacesAndBackslash;
-virSkipSpacesBackwards;
-virStrcpy;
 virStrIsPrint;
-virStrncpy;
-virStrToDouble;
-virStrToLong_i;
-virStrToLong_l;
-virStrToLong_ll;
-virStrToLong_ui;
-virStrToLong_ul;
-virStrToLong_ull;
-virTrimSpaces;
 virValidateWWN;
-virVasprintf;
 
 
 # util/viruuid.h
index 212d0fcdfdfece51690dff9a0b18e9f385edbb12..736174320d51398fc2d74e93a302a475bb21e07f 100644 (file)
@@ -44,6 +44,7 @@
 #include "xen_xm.h"
 #include "virtypedparam.h"
 #include "viruri.h"
+#include "virstring.h"
 
 #define VIR_FROM_THIS VIR_FROM_LIBXL
 
index 97e5d749c2b1c0a9198c2a1d05803a46558c8dcd..0d8ef399ff355ec5bbd2b77671597b839720a568 100644 (file)
@@ -45,6 +45,7 @@
 #include "virrandom.h"
 #include "virhash.h"
 #include "viruuid.h"
+#include "virstring.h"
 
 #include "locking/lock_daemon_dispatch.h"
 #include "locking/lock_protocol.h"
index 12b06e27e25ade7d081e98998377924bc6b856f6..c3d59bd236831909a668134a5135863c3e8ec096 100644 (file)
@@ -30,6 +30,8 @@
 #include "virlog.h"
 #include "rpc/virnetserver.h"
 #include "configmake.h"
+#include "virstring.h"
+#include "virutil.h"
 
 #define VIR_FROM_THIS VIR_FROM_CONF
 
index 4c990882651e7868727d03109b8a311cd4a99ac3..8a92802b3aceb24bbaffc95b59bdcd4a4df09b73 100644 (file)
@@ -24,7 +24,6 @@
 
 #include "rpc/virnetserver.h"
 #include "rpc/virnetserverclient.h"
-#include "virutil.h"
 #include "virlog.h"
 
 #include "lock_daemon.h"
index 4b72a05ab2762822ed1012ece0d1284fa81c3b8a..28a4f15c399f4f3145d2e98fe1cff98af5447c82 100644 (file)
 #include "viralloc.h"
 #include "virlog.h"
 #include "viruuid.h"
-#include "virutil.h"
 #include "virfile.h"
 #include "virerror.h"
 #include "rpc/virnetclient.h"
 #include "lock_protocol.h"
 #include "configmake.h"
 #include "sha256.h"
+#include "virstring.h"
 
 #define VIR_FROM_THIS VIR_FROM_LOCKING
 
index 95f7d61827efc0540c362f70472337de24031cd9..48c6d5694810f5b9016a7049c05a1fe1a227aece 100644 (file)
@@ -40,7 +40,6 @@
 #include "virlog.h"
 #include "virerror.h"
 #include "viralloc.h"
-#include "virutil.h"
 #include "virfile.h"
 #include "md5.h"
 #include "virconf.h"
index ae60caf1c0fa06f29e538b2d87400709dbf9a0e1..82bbe6b7d0224f23b87ede3795645a9828f06a74 100644 (file)
@@ -25,9 +25,9 @@
 #include "lock_driver_nop.h"
 #include "virerror.h"
 #include "virlog.h"
-#include "virutil.h"
 #include "viralloc.h"
 #include "viruuid.h"
+#include "virstring.h"
 
 #if HAVE_DLFCN_H
 # include <dlfcn.h>
index 4a661da44563e3a3b970e20a6fc36c30b286371e..bc3b0d10653507e1c99d625c5c75ca1755641bfe 100644 (file)
@@ -28,6 +28,7 @@
 #include "virlog.h"
 #include "viralloc.h"
 #include "vircgroup.h"
+#include "virstring.h"
 
 #define VIR_FROM_THIS VIR_FROM_LXC
 
index ac0f69c794a4fa04a8cc09979032870a7d995947..ff4069a320fa86ca2144a0345921c81219b41ef9 100644 (file)
@@ -55,7 +55,6 @@
 #include "virerror.h"
 #include "virlog.h"
 #include "lxc_container.h"
-#include "virutil.h"
 #include "viralloc.h"
 #include "virnetdevveth.h"
 #include "viruuid.h"
@@ -64,6 +63,7 @@
 #include "vircommand.h"
 #include "virnetdev.h"
 #include "virprocess.h"
+#include "virstring.h"
 
 #define VIR_FROM_THIS VIR_FROM_LXC
 
index 740b87256e8d79c31be621318fa06a91d7a9f72e..f1800eb4179c04f1fb88a353a154d183a54381ee 100644 (file)
@@ -48,7 +48,6 @@
 
 #include "virerror.h"
 #include "virlog.h"
-#include "virutil.h"
 
 #include "lxc_conf.h"
 #include "lxc_container.h"
@@ -66,6 +65,7 @@
 #include "virprocess.h"
 #include "virnuma.h"
 #include "rpc/virnetserver.h"
+#include "virstring.h"
 
 #define VIR_FROM_THIS VIR_FROM_LXC
 
index 0becdc7862f5f472e7b2df330ed4e06382ea4066..84a97de4fd21526316a5d9c7575e98ff5abf3be5 100644 (file)
@@ -46,7 +46,6 @@
 #include "lxc_driver.h"
 #include "lxc_process.h"
 #include "viralloc.h"
-#include "virutil.h"
 #include "virnetdevbridge.h"
 #include "virnetdevveth.h"
 #include "nodeinfo.h"
@@ -68,6 +67,7 @@
 #include "virtime.h"
 #include "virtypedparam.h"
 #include "viruri.h"
+#include "virstring.h"
 
 #define VIR_FROM_THIS VIR_FROM_LXC
 
index fbd0d56c9517ffd16b60ff4a6fe959b7afcc66a7..b6df99cb913153aeb7033a5b364572e912ad5eec 100644 (file)
@@ -35,6 +35,7 @@
 #include "virlog.h"
 #include "virfile.h"
 #include "virbuffer.h"
+#include "virstring.h"
 
 #define VIR_FROM_THIS VIR_FROM_LXC
 
index ccc9b9248e5777d574a07a7fee04a15ade8d7824..a42c39a15b674b56277a06543b002323472cf6f9 100644 (file)
@@ -32,7 +32,6 @@
 # endif
 
 # include "lxc_conf.h"
-# include "virutil.h"
 # include "viralloc.h"
 
 struct virLXCMeminfo {
index 6d11edacbfb9dba9a7f58ef0aacd8a680db68544..a205d6962f89a8c309a8ece39ffc54e2512f739c 100644 (file)
@@ -30,6 +30,7 @@
 #include "virlog.h"
 #include "virthread.h"
 #include "rpc/virnetclient.h"
+#include "virstring.h"
 
 #define VIR_FROM_THIS VIR_FROM_LXC
 
index ab07a1e514493a48a2f027dc5040971c1e0be08a..b10e81c4d9f1645006bde5edb40725e8ef2efab5 100644 (file)
@@ -47,6 +47,7 @@
 #include "vircommand.h"
 #include "lxc_hostdev.h"
 #include "virhook.h"
+#include "virstring.h"
 
 #define VIR_FROM_THIS VIR_FROM_LXC
 
index 8da28e45d0de3b839fb9acbbfdd85406199e9777..35202f178110bfbde988dd2e0a383d769b80329f 100644 (file)
@@ -51,7 +51,6 @@
 #include "driver.h"
 #include "virbuffer.h"
 #include "virpidfile.h"
-#include "virutil.h"
 #include "vircommand.h"
 #include "viralloc.h"
 #include "viruuid.h"
@@ -66,6 +65,7 @@
 #include "virnetdevvportprofile.h"
 #include "virdbus.h"
 #include "virfile.h"
+#include "virstring.h"
 
 #define NETWORK_PID_DIR LOCALSTATEDIR "/run/libvirt/network"
 #define NETWORK_STATE_DIR LOCALSTATEDIR "/lib/libvirt/network"
index c9bd68b65c8d7442c5909ac5bf3e727ba695c81b..95df2e5a7fa22f1b32b0a1461d73c69c6a2f0a91 100644 (file)
@@ -36,7 +36,6 @@
 #include "node_device_conf.h"
 #include "node_device_hal.h"
 #include "node_device_driver.h"
-#include "virutil.h"
 
 #define VIR_FROM_THIS VIR_FROM_NODEDEV
 
index fd9143062056745d979bffcf4f2bf403afdb805f..71c717269e670b6839684a0824c6a239ea7b9a1e 100644 (file)
@@ -32,6 +32,7 @@
 #include "viralloc.h"
 #include "virlog.h"
 #include "virfile.h"
+#include "virstring.h"
 
 #define VIR_FROM_THIS VIR_FROM_NODEDEV
 
index f98841e96f1b6991d22e6ccaee061a3d52c458e1..c3c97d7c8a9220d92ae9bec4784755365e595e10 100644 (file)
@@ -36,9 +36,9 @@
 #include "virlog.h"
 #include "viralloc.h"
 #include "viruuid.h"
-#include "virutil.h"
 #include "virbuffer.h"
 #include "virpci.h"
+#include "virstring.h"
 
 #define VIR_FROM_THIS VIR_FROM_NODEDEV
 
index a5b5608ed325e4df51965a3d9096390c8b2d81c5..95c2f33926a4228ba1aac4818c7ae1d98ba7919c 100644 (file)
@@ -47,7 +47,6 @@
 #include "viralloc.h"
 #include "nodeinfo.h"
 #include "physmem.h"
-#include "virutil.h"
 #include "virlog.h"
 #include "virerror.h"
 #include "count-one-bits.h"
@@ -55,7 +54,7 @@
 #include "virarch.h"
 #include "virfile.h"
 #include "virtypedparam.h"
-
+#include "virstring.h"
 
 #define VIR_FROM_THIS VIR_FROM_NONE
 
index 5012b14d17b937a9052738c92516b79e49218cc7..df11e891345d7af7736f049796d4f1804974dbd1 100644 (file)
@@ -68,6 +68,7 @@
 #include "virthreadpool.h"
 #include "configmake.h"
 #include "virtime.h"
+#include "virstring.h"
 
 #define VIR_FROM_THIS VIR_FROM_NWFILTER
 
index 789280785ba141277471604c1f9f06592d574229..7eec3de40bfa8aadd9bafbe931e8797aab88ded1 100644 (file)
@@ -41,6 +41,7 @@
 #include "nwfilter_driver.h"
 #include "nwfilter_gentech_driver.h"
 #include "configmake.h"
+#include "virstring.h"
 
 #include "nwfilter_ipaddrmap.h"
 #include "nwfilter_dhcpsnoop.h"
index 0e39574edb318a9c77e8844d92f8b8aafee854b5..ac943555ea4abce997c35a172faa4c3ece9d5867 100644 (file)
@@ -43,7 +43,7 @@
 #include "vircommand.h"
 #include "configmake.h"
 #include "intprops.h"
-
+#include "virstring.h"
 
 #define VIR_FROM_THIS VIR_FROM_NWFILTER
 
index b399092ef043e0d0a1c09ca455b1c75edee6d791..14fd32cfc62879726b8fa160eea481eecab867f0 100644 (file)
@@ -54,6 +54,7 @@
 #include "nwfilter_ebiptables_driver.h"
 #include "nwfilter_ipaddrmap.h"
 #include "nwfilter_learnipaddr.h"
+#include "virstring.h"
 
 #define VIR_FROM_THIS VIR_FROM_NWFILTER
 
index a6f96c717f9eb6763859fc9cdb18494937a1c7d5..49fae2894caa95d61bb01ee7f818332d97755ded 100644 (file)
 #include "viruuid.h"
 #include "virbuffer.h"
 #include "viralloc.h"
-#include "virutil.h"
 #include "nodeinfo.h"
 #include "virfile.h"
 #include "vircommand.h"
+#include "virstring.h"
 
 #define VIR_FROM_THIS VIR_FROM_OPENVZ
 
index f8bec6239cb8cfb641fa43ae7ac719f33488e7d2..e6d71466adb15eba34290188fecbc7dea0d6f7b7 100644 (file)
@@ -48,7 +48,6 @@
 #include "openvz_driver.h"
 #include "openvz_util.h"
 #include "virbuffer.h"
-#include "virutil.h"
 #include "openvz_conf.h"
 #include "nodeinfo.h"
 #include "viralloc.h"
@@ -58,6 +57,7 @@
 #include "vircommand.h"
 #include "viruri.h"
 #include "virstatslinux.h"
+#include "virstring.h"
 
 #define VIR_FROM_THIS VIR_FROM_OPENVZ
 
index e1269672bdd8c7c0103b05e5beac00e72fe75ad4..c29a5ba24d3be5e65849b5c610dfbb52bfdec88c 100644 (file)
 #include "datatypes.h"
 #include "virerror.h"
 #include "viralloc.h"
-#include "virutil.h"
 #include "virlog.h"
 #include "vircommand.h"
 #include "configmake.h"
 #include "virstoragefile.h"
 #include "nodeinfo.h"
 #include "c-ctype.h"
+#include "virstring.h"
 
 #include "parallels_driver.h"
 #include "parallels_utils.h"
index 7a9436f8608205044b6c37a49b7211920e5812c7..23109d38436c8c3f8d77a023f98848a323a02b21 100644 (file)
@@ -28,8 +28,8 @@
 #include "viralloc.h"
 #include "virerror.h"
 #include "md5.h"
-
 #include "parallels_utils.h"
+#include "virstring.h"
 
 #define VIR_FROM_THIS VIR_FROM_PARALLELS
 #define PARALLELS_ROUTED_NETWORK_UUID   "eb593dd1-6846-45b0-84a0-de0729286982"
index 271f3709dc17aeb5b54008840dc8f150eb4b78e5..4c98e4389db6c666154c2b794f2328f6131c71dd 100644 (file)
@@ -36,8 +36,8 @@
 #include "configmake.h"
 #include "virstoragefile.h"
 #include "virerror.h"
-
 #include "parallels_utils.h"
+#include "virstring.h"
 
 #define VIR_FROM_THIS VIR_FROM_PARALLELS
 
index 0b589abd234264b41b23f6ade30becbbf0c0bc43..4236ed5073bbb66c9060cf855cf239a33421c908 100644 (file)
@@ -28,8 +28,8 @@
 #include "virerror.h"
 #include "viralloc.h"
 #include "virjson.h"
-
 #include "parallels_utils.h"
+#include "virstring.h"
 
 #define VIR_FROM_THIS VIR_FROM_PARALLELS
 
index f5c66ba56a0634542eabfd0c9228c79ae5dcd526..85eb650645982ed8d054592cf7690077e94f0aa0 100644 (file)
@@ -43,7 +43,6 @@
 
 #include "internal.h"
 #include "virauth.h"
-#include "virutil.h"
 #include "datatypes.h"
 #include "virbuffer.h"
 #include "viralloc.h"
@@ -56,8 +55,8 @@
 #include "nodeinfo.h"
 #include "virfile.h"
 #include "interface_conf.h"
-
 #include "phyp_driver.h"
+#include "virstring.h"
 
 #define VIR_FROM_THIS VIR_FROM_PHYP
 
index 8c8c38bab03f006f3b21ca63bb3e5e464efe9d16..d116b2394f22cfc8730e8aa14c1aeeed14a1be16 100644 (file)
@@ -41,6 +41,7 @@
 #include "virprocess.h"
 #include "virtime.h"
 #include "virobject.h"
+#include "virstring.h"
 
 #define VIR_FROM_THIS VIR_FROM_QEMU
 
index 3bc1141a4d00a202c89ab82b3f23f2915574f423..ab4db9a0ad7a173cc0f7b39ce7c210a3f73a5bef 100644 (file)
@@ -25,7 +25,6 @@
 #include "virebtables.h"
 #include "qemu_conf.h"
 #include "qemu_driver.h"
-#include "virutil.h"
 #include "virerror.h"
 #include "virlog.h"
 
index 2acf535e2c50ac2956e5ed2a73dda22a32ec92d4..a3a8d1feedfea3efc7b91a4835d34f6a8be24ec5 100644 (file)
@@ -27,7 +27,6 @@
 #include "viralloc.h"
 #include "virlog.h"
 #include "virerror.h"
-#include "virutil.h"
 #include "virfile.h"
 #include "virpidfile.h"
 #include "virprocess.h"
index 7a7824d83f82a9d48a2ccec8765dca8c73f595b6..4819cfe99b30ebd6847f01ae329f8cc43a3e2ee9 100644 (file)
@@ -30,7 +30,6 @@
 #include "virlog.h"
 #include "viralloc.h"
 #include "virerror.h"
-#include "virutil.h"
 #include "domain_audit.h"
 
 #define VIR_FROM_THIS VIR_FROM_QEMU
index 7d851e37864d9e88e50500d65cb5aaf54794c51d..575dce1376d67c20780580869928b1ae96bcf74b 100644 (file)
@@ -33,7 +33,6 @@
 #include "virlog.h"
 #include "virarch.h"
 #include "virerror.h"
-#include "virutil.h"
 #include "virfile.h"
 #include "virnetdev.h"
 #include "virstring.h"
index 7c3f317cf0d2e94f5770fd24a64f2c8c35a43719..c16b90d3feedfbb7bbc0772df86a49b9dd6c84d4 100644 (file)
@@ -42,7 +42,6 @@
 #include "viruuid.h"
 #include "virbuffer.h"
 #include "virconf.h"
-#include "virutil.h"
 #include "viralloc.h"
 #include "datatypes.h"
 #include "virxml.h"
index 1ea2bcd76e95919d86ff8fe9ddb2931124edf3ee..47edfba9e54a722e6ded808fc8fcc8929e189e2b 100644 (file)
@@ -37,6 +37,7 @@
 #include "domain_event.h"
 #include "virtime.h"
 #include "virstoragefile.h"
+#include "virstring.h"
 
 #include <sys/time.h>
 #include <fcntl.h>
index 94928508f03aafc43768725420c4d7b5a5accbac..d5d7de39064ef8a1c6a6f3844a4c57bbd77d1ff0 100644 (file)
@@ -61,7 +61,6 @@
 #include "virlog.h"
 #include "datatypes.h"
 #include "virbuffer.h"
-#include "virutil.h"
 #include "nodeinfo.h"
 #include "virstatslinux.h"
 #include "capabilities.h"
@@ -92,6 +91,7 @@
 #include "virtime.h"
 #include "virtypedparam.h"
 #include "virbitmap.h"
+#include "virstring.h"
 
 #define VIR_FROM_THIS VIR_FROM_QEMU
 
index 0d1ca4501642c47c889c279aa6cf199550797d6e..a4f48b0338a62f225c9251a68aee83e6b28fceb1 100644 (file)
@@ -47,6 +47,7 @@
 #include "virnetdevtap.h"
 #include "device_conf.h"
 #include "virstoragefile.h"
+#include "virstring.h"
 
 #define VIR_FROM_THIS VIR_FROM_QEMU
 #define CHANGE_MEDIA_RETRIES 10
index 6ad1c307f3af20662b2e17f7884bbe9924aea6b3..0732614f762e5b5a0578c98ff97bdaf104934f73 100644 (file)
@@ -44,7 +44,6 @@
 #include "virlog.h"
 #include "virerror.h"
 #include "viralloc.h"
-#include "virutil.h"
 #include "virfile.h"
 #include "datatypes.h"
 #include "fdstream.h"
@@ -55,7 +54,7 @@
 #include "virstoragefile.h"
 #include "viruri.h"
 #include "virhook.h"
-
+#include "virstring.h"
 
 #define VIR_FROM_THIS VIR_FROM_QEMU
 
index 1b1d4a18d84dcaa2cfda3c7673977af42b670f1d..4deb2d60ac7869a2b5f7412b2183a81d61c839ea 100644 (file)
@@ -37,6 +37,7 @@
 #include "virfile.h"
 #include "virprocess.h"
 #include "virobject.h"
+#include "virstring.h"
 
 #ifdef WITH_DTRACE_PROBES
 # include "libvirt_qemu_probes.h"
index daade3d554c9160b5cd5c3f82cb5375173fe152c..696961bdab1ae7f62f2613707c1e6842703a0e57 100644 (file)
@@ -40,6 +40,7 @@
 #include "datatypes.h"
 #include "virerror.h"
 #include "virbuffer.h"
+#include "virstring.h"
 
 #ifdef WITH_DTRACE_PROBES
 # include "libvirt_qemu_probes.h"
index 58f64b7310f24489a4d3d9dccdc1935808804e59..3dd178c19cfc28f7c26f439670e0f2a511da7434 100644 (file)
@@ -50,7 +50,6 @@
 #include "virhook.h"
 #include "virfile.h"
 #include "virpidfile.h"
-#include "virutil.h"
 #include "c-ctype.h"
 #include "nodeinfo.h"
 #include "domain_audit.h"
@@ -64,6 +63,7 @@
 #include "virbitmap.h"
 #include "viratomic.h"
 #include "virnuma.h"
+#include "virstring.h"
 
 #define VIR_FROM_THIS VIR_FROM_QEMU
 
index f66304c3f9f2021380f579ebc387e3a9d5cdd43d..13212d08b05f1fbe4be1bc1f932f116f0cf63bdb 100644 (file)
@@ -40,7 +40,6 @@
 #include "lxc_protocol.h"
 #include "qemu_protocol.h"
 #include "viralloc.h"
-#include "virutil.h"
 #include "virfile.h"
 #include "vircommand.h"
 #include "intprops.h"
@@ -48,6 +47,7 @@
 #include "viruri.h"
 #include "virauth.h"
 #include "virauthconfig.h"
+#include "virstring.h"
 
 #define VIR_FROM_THIS VIR_FROM_REMOTE
 
index d49082ca96a87a9c10f0323b8a3ce6c0bf05a1c0..8ae5c6c24e07aece1a16d5302f2f9522fb6a202a 100644 (file)
@@ -26,7 +26,6 @@
 #include "virthread.h"
 #include "virfile.h"
 #include "virlog.h"
-#include "virutil.h"
 #include "virerror.h"
 #include "virnetsocket.h"
 #include "virkeepaliveprotocol.h"
index 58fb0b4918f58c45d1b69afb13a0f5400fcc9706..2bde5c74e59ddda3420bce276a6b8455907522f0 100644 (file)
@@ -34,6 +34,8 @@
 #include "viralloc.h"
 #include "virthread.h"
 #include "virkeepalive.h"
+#include "virstring.h"
+#include "virutil.h"
 
 #define VIR_FROM_THIS VIR_FROM_RPC
 
index c4fd9ee98157369cd8819d8e3252c8664bdb81b1..e950d7fd77f56973baab9766dcdfc2a6b5280c58 100644 (file)
@@ -52,7 +52,7 @@
 #include "virfile.h"
 #include "virthread.h"
 #include "virprocess.h"
-
+#include "virstring.h"
 #include "passfd.h"
 
 #if WITH_SSH2
index 9ce99f85cdc2c253953623bdcdad149d98c43fcd..27750fc66bbba69c5f2df45105a6842387dd1212 100644 (file)
@@ -34,6 +34,7 @@
 #include "virutil.h"
 #include "virerror.h"
 #include "virobject.h"
+#include "virstring.h"
 
 #define VIR_FROM_THIS VIR_FROM_SSH
 
index eed0439c3214167eb9bc770a217abd464be6a6f9..7f5975dcffc58fe2154d37710ccf419f3875f32d 100644 (file)
@@ -29,6 +29,7 @@
 #include "gnutls_1_0_compat.h"
 
 #include "virnettlscontext.h"
+#include "virstring.h"
 
 #include "viralloc.h"
 #include "virerror.h"
index 646c8ffc93a8a12a20736ee7f47768c8efd31e23..377b9f4c45911066657d969f927720fc0db5f539 100644 (file)
 #include "secret_conf.h"
 #include "secret_driver.h"
 #include "virthread.h"
-#include "virutil.h"
 #include "viruuid.h"
 #include "virerror.h"
 #include "virfile.h"
 #include "configmake.h"
+#include "virstring.h"
 
 #define VIR_FROM_THIS VIR_FROM_SECRET
 
index 5be5ff02d98cfb692f18324ce0327da132edd5ad..5fb5db318dbb50297cd8a6ed3dd2beea8c867863 100644 (file)
@@ -38,7 +38,6 @@
 #include "internal.h"
 
 #include "security_apparmor.h"
-#include "virutil.h"
 #include "viralloc.h"
 #include "virerror.h"
 #include "datatypes.h"
@@ -49,6 +48,7 @@
 #include "configmake.h"
 #include "vircommand.h"
 #include "virlog.h"
+#include "virstring.h"
 
 #define VIR_FROM_THIS VIR_FROM_SECURITY
 #define SECURITY_APPARMOR_VOID_DOI      "0"
index e197eff42eef52798dee6e8d6efabfb03f91ac1e..cd214d886063f9fc11d80dd5f851262d6a798985 100644 (file)
 
 #include "security_dac.h"
 #include "virerror.h"
-#include "virutil.h"
 #include "viralloc.h"
 #include "virlog.h"
 #include "virpci.h"
 #include "virusb.h"
 #include "virstoragefile.h"
+#include "virstring.h"
 
 #define VIR_FROM_THIS VIR_FROM_SECURITY
 #define SECURITY_DAC_NAME "dac"
index 0cf40093586c1f0057b041252e97c1c73f097cf6..a85f0a3c94f75413189ca1088345871113c750b1 100644 (file)
@@ -34,7 +34,6 @@
 #include "security_driver.h"
 #include "security_selinux.h"
 #include "virerror.h"
-#include "virutil.h"
 #include "viralloc.h"
 #include "virlog.h"
 #include "virpci.h"
@@ -45,6 +44,7 @@
 #include "virrandom.h"
 #include "virconf.h"
 #include "virtpm.h"
+#include "virstring.h"
 
 #define VIR_FROM_THIS VIR_FROM_SECURITY
 
index 3c9515f19fd1eb0a8916efe8122ed7df4530e73a..b52691992f335e0c00c7f32561f43f38a21ddbc4 100644 (file)
@@ -41,7 +41,6 @@
 
 #include "internal.h"
 #include "virbuffer.h"
-#include "virutil.h"
 #include "viralloc.h"
 #include "vircommand.h"
 
@@ -55,6 +54,7 @@
 #include "virfile.h"
 #include "configmake.h"
 #include "virrandom.h"
+#include "virstring.h"
 
 #define VIR_FROM_THIS VIR_FROM_SECURITY
 
index d4aabb6bca71ddb2999add49a9048ba4c3207211..b85a5a9aa89780a93fa9472ca083f0ea69d35b74 100644 (file)
@@ -45,7 +45,6 @@
 
 #include "datatypes.h"
 #include "virerror.h"
-#include "virutil.h"
 #include "viralloc.h"
 #include "internal.h"
 #include "secret_conf.h"
@@ -55,6 +54,7 @@
 #include "virlog.h"
 #include "virfile.h"
 #include "stat-time.h"
+#include "virstring.h"
 
 #if WITH_STORAGE_LVM
 # include "storage_backend_logical.h"
index 1faf1aed36c52d24a70ea0795545ecaa6a5a4cf8..6da2d124748fe886f483bf3805ce28d2fa35cc3a 100644 (file)
 #include "virerror.h"
 #include "virlog.h"
 #include "storage_backend_disk.h"
-#include "virutil.h"
 #include "viralloc.h"
 #include "vircommand.h"
 #include "configmake.h"
+#include "virstring.h"
 
 #define VIR_FROM_THIS VIR_FROM_STORAGE
 
index c1684f77cb487c2b095d8b133824755ca9a21903..8288b1e7c8040ff0a26697161bc18a7e3d65635e 100644 (file)
@@ -50,6 +50,7 @@
 #include "virxml.h"
 #include "virfile.h"
 #include "virlog.h"
+#include "virstring.h"
 
 #define VIR_FROM_THIS VIR_FROM_STORAGE
 
index f6b76ed4969eb6ba676910f7afef7ffb1820a594..cf259193a678e845421df02d2c20ee6eee6ad252 100644 (file)
 #include "virerror.h"
 #include "storage_backend_scsi.h"
 #include "storage_backend_iscsi.h"
-#include "virutil.h"
 #include "viralloc.h"
 #include "virlog.h"
 #include "virfile.h"
 #include "vircommand.h"
 #include "virrandom.h"
+#include "virstring.h"
 
 #define VIR_FROM_THIS VIR_FROM_STORAGE
 
index 4cf664775e1ccb8e66c2cf39a8a3613acccaaa44..316043fe728593b868342a8c4ce505d9b2875082 100644 (file)
@@ -38,6 +38,7 @@
 #include "viralloc.h"
 #include "virlog.h"
 #include "virfile.h"
+#include "virstring.h"
 
 #define VIR_FROM_THIS VIR_FROM_STORAGE
 
index 60490634f8b9ff822a608777efdaab3771a23fc4..6e742f77cd93403c88791bd67729233d6b4f9e00 100644 (file)
@@ -35,6 +35,7 @@
 #include "viralloc.h"
 #include "virlog.h"
 #include "virfile.h"
+#include "virstring.h"
 
 #define VIR_FROM_THIS VIR_FROM_STORAGE
 
index e815192c22a014cbe85ee197b01219b3deb95b21..ca23d4b0fb9f8be03b81c80b3839481319c39a70 100644 (file)
@@ -26,7 +26,6 @@
 #include "virerror.h"
 #include "storage_backend_rbd.h"
 #include "storage_conf.h"
-#include "virutil.h"
 #include "viralloc.h"
 #include "virlog.h"
 #include "base64.h"
index 987d218509b6d2839d5e50e06d6b35fb2ec4ad94..154a56aa8ece13ff28fcd0bbade4f535d33a5a4b 100644 (file)
@@ -34,6 +34,7 @@
 #include "virlog.h"
 #include "virfile.h"
 #include "vircommand.h"
+#include "virstring.h"
 
 #define VIR_FROM_THIS VIR_FROM_STORAGE
 
index 15fa29c7e2214222b0bfcf9a8af01fd3d51d6488..dfa5673257308cfa7f1673f2b9d6bc32d56162c9 100644 (file)
@@ -30,7 +30,6 @@
 #include "storage_backend_sheepdog.h"
 #include "storage_conf.h"
 #include "vircommand.h"
-#include "virutil.h"
 #include "viralloc.h"
 #include "virlog.h"
 
index f190eb7b7eeecee01a97d2c4860b8bfc874cee9d..990f0b178b8c5d15603e55ab086111492c3f2f33 100644 (file)
@@ -39,7 +39,6 @@
 #include "virerror.h"
 #include "datatypes.h"
 #include "driver.h"
-#include "virutil.h"
 #include "storage_driver.h"
 #include "storage_conf.h"
 #include "viralloc.h"
@@ -48,6 +47,7 @@
 #include "virfile.h"
 #include "fdstream.h"
 #include "configmake.h"
+#include "virstring.h"
 
 #define VIR_FROM_THIS VIR_FROM_STORAGE
 
index d964fb2e6feb56da18bb5e3b63e408785ee9b084..f60f106bb82124d215c8c5fc35b84cfa2dcf08e5 100644 (file)
@@ -36,7 +36,6 @@
 #include "datatypes.h"
 #include "test_driver.h"
 #include "virbuffer.h"
-#include "virutil.h"
 #include "viruuid.h"
 #include "capabilities.h"
 #include "configmake.h"
@@ -54,6 +53,7 @@
 #include "virfile.h"
 #include "virtypedparam.h"
 #include "virrandom.h"
+#include "virstring.h"
 
 #define VIR_FROM_THIS VIR_FROM_TEST
 
index 4fa79271faa367d471c4bce7842b60096edb0516..a55b5b1f103cdfbbd7e25ac28edf4832d3373556 100644 (file)
@@ -38,7 +38,6 @@
 #include "viruuid.h"
 #include "virbuffer.h"
 #include "virconf.h"
-#include "virutil.h"
 #include "viralloc.h"
 #include "nodeinfo.h"
 #include "virlog.h"
@@ -47,7 +46,7 @@
 #include "vircommand.h"
 #include "virnetdevtap.h"
 #include "virnodesuspend.h"
-
+#include "virstring.h"
 
 #define VIR_FROM_THIS VIR_FROM_UML
 
index 9b0aba6f093d8473f31687360ff8d3494434a8d1..66c00b2beb0f2e476d6439b8a720d4265a2306cb 100644 (file)
@@ -46,7 +46,6 @@
 #include "uml_driver.h"
 #include "uml_conf.h"
 #include "virbuffer.h"
-#include "virutil.h"
 #include "nodeinfo.h"
 #include "virstatslinux.h"
 #include "capabilities.h"
@@ -65,6 +64,7 @@
 #include "virnodesuspend.h"
 #include "virprocess.h"
 #include "viruri.h"
+#include "virstring.h"
 
 #define VIR_FROM_THIS VIR_FROM_UML
 
index 2230bcbbd438df19912d07a57ded6f9971cd44ed..33ba85240a1f1f461f847a98d969356558633a12 100644 (file)
@@ -40,6 +40,7 @@
 #include "virerror.h"
 #include "configmake.h"
 #include "virrandom.h"
+#include "virstring.h"
 
 #define VIR_FROM_THIS VIR_FROM_STORAGE
 
index 0f4bb4f4a8a3014e0f9c05d7210ebfa5631d224b..5dd4e1fc74f06152da4ed920a0fab01f618220be 100644 (file)
@@ -30,9 +30,9 @@
 #include "virerror.h"
 #include "virlog.h"
 #include "viraudit.h"
-#include "virutil.h"
 #include "virfile.h"
 #include "viralloc.h"
+#include "virstring.h"
 
 /* Provide the macros in case the header file is old.
    FIXME: should be removed. */
index c26e340ddd9826434edd052671d4c24813a2e29e..fdcefe1a063966f5371ba36769c010a43e15597a 100644 (file)
@@ -32,6 +32,7 @@
 #include "virerror.h"
 #include "configmake.h"
 #include "virauthconfig.h"
+#include "virstring.h"
 
 #define VIR_FROM_THIS VIR_FROM_AUTH
 
index 1d1f084ae23273ab929cdb59420c369d6ee8b9c4..4259cb3bade7f406fd973203d21f5cf6ad821ead 100644 (file)
 
 #include "virkeyfile.h"
 #include "viralloc.h"
-#include "virutil.h"
 #include "virlog.h"
 #include "virerror.h"
-
+#include "virstring.h"
 
 struct _virAuthConfig {
     virKeyFilePtr keyfile;
index 998c302567ce9216a0e765e305babd578918af10..c81555acdad7807e19d4e4e1e7664798261dc4b8 100644 (file)
 #include "virbitmap.h"
 #include "viralloc.h"
 #include "virbuffer.h"
-#include "virutil.h"
 #include "c-ctype.h"
 #include "count-one-bits.h"
-
+#include "virstring.h"
 
 struct _virBitmap {
     size_t max_bit;
index 98521ec9ec7845a2c3ef146f73bb3b1534eecc09..f6f27d9e714fd6d0cfb8c587f2f1432b6601fde2 100644 (file)
@@ -50,6 +50,7 @@
 #include "virprocess.h"
 #include "virbuffer.h"
 #include "virthread.h"
+#include "virstring.h"
 
 #define VIR_FROM_THIS VIR_FROM_NONE
 
index 18568feb873db1e96cefa94757950005ac8afdb8..a4021392d13da79fa62a0b942369fe62ae3721f9 100644 (file)
@@ -23,7 +23,6 @@
 # define __VIR_COMMAND_H__
 
 # include "internal.h"
-# include "virutil.h"
 # include "virbuffer.h"
 
 typedef struct _virCommand virCommand;
index 2e63d83af2174ee3456ed8d3f5a0d7e55845d828..4f0563317bf50c7c5310ab3623ffd7c8049fdff2 100644 (file)
@@ -49,6 +49,7 @@
 #include "virerror.h"
 #include "virlog.h"
 #include "virfile.h"
+#include "virstring.h"
 
 #define VIR_FROM_THIS VIR_FROM_NETWORK
 #define DNSMASQ_HOSTSFILE_SUFFIX "hostsfile"
index 65c0ac33b4daec5c5e15d75cd752474094197175..6bc6fed3ca88679438f6ddd790e61e80897b6395 100644 (file)
@@ -48,6 +48,8 @@
 #include "virerror.h"
 #include "virlog.h"
 #include "virthread.h"
+#include "virstring.h"
+#include "virutil.h"
 
 #if HAVE_FIREWALLD
 static char *firewall_cmd_path = NULL;
index 8a329a98258c5b9019a20096e83ee0eae6a0b81e..af4da8c8fb7ccda73e37f47c1a2529c39f3121d0 100644 (file)
@@ -33,6 +33,7 @@
 #include "viralloc.h"
 #include "virthread.h"
 #include "virutil.h"
+#include "virstring.h"
 
 virThreadLocal virLastErr;
 
index fbaeeddbe8972cd0314f825b0b3dc549fa0c332a..25a0501cdf179b1700fc9d5117ce7cad127f1440 100644 (file)
@@ -42,6 +42,7 @@
 #include "viralloc.h"
 #include "virerror.h"
 #include "virlog.h"
+#include "virstring.h"
 
 #define VIR_FROM_THIS VIR_FROM_NONE
 
index a63a12536ae421635aef4e92c2936d4257ebd5fb..96bf4cf126c672308909d8545c74ba0de4712b92 100644 (file)
@@ -25,7 +25,6 @@
 # define __VIR_HOOKS_H__
 
 # include "internal.h"
-# include "virutil.h"
 
 enum virHookDriverType {
     VIR_HOOK_DRIVER_DAEMON = 0,        /* Daemon related events */
index d1e0fe6e51a491010d60c3391a3ab29b35381999..59db0575a2eb3fe00c58f17508fee1cc15cda7d0 100644 (file)
@@ -32,6 +32,7 @@
 #include "virutil.h"
 #include "viralloc.h"
 #include "virfile.h"
+#include "virstring.h"
 
 #define VIR_FROM_THIS VIR_FROM_INITCTL
 
index 19d61610c8c49d6d2d0d3ed62709d15d6f17354d..06a1356cf21f07e364f099369c83725f56d575dd 100644 (file)
@@ -46,6 +46,8 @@
 #include "virerror.h"
 #include "virlog.h"
 #include "virthread.h"
+#include "virstring.h"
+#include "virutil.h"
 
 #if HAVE_FIREWALLD
 static char *firewall_cmd_path = NULL;
index e6a3b1b61ef5f34eb4295d434b13796aad4cda76..92138d36730b652cc57e213c3fc8c82ee92db676 100644 (file)
@@ -27,6 +27,7 @@
 #include "viralloc.h"
 #include "virerror.h"
 #include "virlog.h"
+#include "virstring.h"
 #include "virutil.h"
 
 #if WITH_YAJL
index 4ff0f3a329c0d09b3334267a1c47cdfd617b3abf..620a460ee2a8ebc287dfad57a1145c3c187d8274 100644 (file)
@@ -29,6 +29,7 @@
 #include "virfile.h"
 #include "virhash.h"
 #include "virthread.h"
+#include "virstring.h"
 
 #include <fcntl.h>
 #include <unistd.h>
index e31abb091c8d65cd9ab237dae5825f3bfea4180e..bd47b38e2c11fb97da55a5ee4c184e9e2b11d31d 100644 (file)
@@ -50,6 +50,7 @@
 #include "virfile.h"
 #include "virtime.h"
 #include "intprops.h"
+#include "virstring.h"
 
 /* Journald output is only supported on Linux new enough to expose
  * htole64.  */
index 8013f233462d47acd4410a6b9462aea292b43efb..d987b8eb21b0f628fa35dc3deae7429a18ebd3a0 100644 (file)
@@ -30,6 +30,8 @@
 #include "viralloc.h"
 #include "virpci.h"
 #include "virlog.h"
+#include "virstring.h"
+#include "virutil.h"
 
 #include <sys/ioctl.h>
 #include <net/if.h>
index 2c5b63a0d29f9d607a1c9c80fef1aacdf7db7415..ccc1449d7695253845e1f138ffebf0500a448eca 100644 (file)
@@ -26,6 +26,7 @@
 #include "vircommand.h"
 #include "viralloc.h"
 #include "virerror.h"
+#include "virstring.h"
 
 #define VIR_FROM_THIS VIR_FROM_NONE
 
index 9d46cc4a3fa9972497d14f865ada049a37f278f8..130829cede0987d019fba28589086cc522e808d0 100644 (file)
@@ -28,6 +28,7 @@
 #include "virfile.h"
 #include "viralloc.h"
 #include "intprops.h"
+#include "virstring.h"
 
 #include <sys/ioctl.h>
 #include <sys/socket.h>
index e76e94c5d5015eb962fd5a525360cea8d5dd8e94..0c4fcbdd79b1a40bfa1bc2daff72305493c7bb8e 100644 (file)
@@ -29,7 +29,6 @@
 
 #include "virnetdevmacvlan.h"
 #include "virmacaddr.h"
-#include "virutil.h"
 #include "virerror.h"
 #include "virthread.h"
 
index 4fe077aa347473701f6bf5ae8ec2c50443d478ba..2aee445a5844071a0e39bc4367988f11c7cd29a1 100644 (file)
@@ -28,6 +28,7 @@
 #include "viralloc.h"
 #include "virerror.h"
 #include "virmacaddr.h"
+#include "virstring.h"
 
 #define VIR_FROM_THIS VIR_FROM_NONE
 
index 3216ea01e3ba7a093cd48bd1a8e75a95eb57b949..0852e4d8704d7ebf2143a6bad079da28920b58c5 100644 (file)
@@ -25,7 +25,6 @@
 # define __VIR_NETDEV_OPENVSWITCH_H__
 
 # include "internal.h"
-# include "virutil.h"
 # include "virnetdevvportprofile.h"
 # include "virnetdevvlan.h"
 
index 7d77f819fd4c61d49ba96e245a81468609e46b89..75599db807a99be5132c79f6a5214e8fbdd128b9 100644 (file)
@@ -31,7 +31,7 @@
 #include "virfile.h"
 #include "viralloc.h"
 #include "virlog.h"
-#include "virutil.h"
+#include "virstring.h"
 
 #include <sys/ioctl.h>
 #include <net/if.h>
index 3f81655e4004578ba2764b538f804d34f2af5620..5daf21ef7b23c4add76ea42d077d4c96ba913acd 100644 (file)
@@ -30,6 +30,8 @@
 #include "virlog.h"
 #include "vircommand.h"
 #include "virerror.h"
+#include "virstring.h"
+#include "virutil.h"
 
 #define VIR_FROM_THIS VIR_FROM_NONE
 
index 13ccbab1c839d3e45587cf3d651de18b42d94e48..883aa46b3c3ecf6ffa0669c83a7ce0534a0d92f9 100644 (file)
@@ -25,6 +25,7 @@
 #include "virnetdevvportprofile.h"
 #include "virerror.h"
 #include "viralloc.h"
+#include "virstring.h"
 
 #define VIR_FROM_THIS VIR_FROM_NET
 
index ba60292f15f6627f3b23c239d52004f4892bb79d..58656139865ba0ea3919a2b7d0be8ae9c4262247 100644 (file)
@@ -42,6 +42,8 @@
 #include "vircommand.h"
 #include "virerror.h"
 #include "virfile.h"
+#include "virstring.h"
+#include "virutil.h"
 
 #define PCI_SYSFS "/sys/bus/pci/"
 #define PCI_ID_LEN 10   /* "XXXX XXXX" */
index 14c9f9f08f7e322b297ef77f426dde2a882700eb..298d57c94c534e7d7d6e3f4bd3759d6c045057af 100644 (file)
@@ -36,6 +36,7 @@
 #include "virerror.h"
 #include "c-ctype.h"
 #include "areadlink.h"
+#include "virstring.h"
 
 #define VIR_FROM_THIS VIR_FROM_NONE
 
index fb818059f8bb1cedf91bcf1eeb09bc742433caed..73f512313fb98cd6ad9c32d06cee66280f071015 100644 (file)
@@ -39,6 +39,7 @@
 #include "virfile.h"
 #include "virlog.h"
 #include "virutil.h"
+#include "virstring.h"
 
 #define VIR_FROM_THIS VIR_FROM_NONE
 
index 6c5bc9162ece7d0388b088ffca0490bb361f51da..f46d7023e56de9cabdec85e841327d7f88a3a59a 100644 (file)
@@ -32,6 +32,7 @@
 #include "virutil.h"
 #include "virerror.h"
 #include "virlog.h"
+#include "virstring.h"
 
 #define VIR_FROM_THIS VIR_FROM_NONE
 
index 81dfbe61e3ed9d400e8132bb46af6486f42080df..23b678113563feee57aba9c537d71c130ba1d097 100644 (file)
@@ -30,8 +30,8 @@
 
 #include "virerror.h"
 #include "virsexpr.h"
-#include "virutil.h"
 #include "viralloc.h"
+#include "virstring.h"
 
 #define VIR_FROM_THIS VIR_FROM_SEXPR
 
index 7ee450bb9e88eb8d1f7e31620d5380b4e79d75e7..d6a0d934f9c15fc5166db5a20367e57c0697aff4 100644 (file)
@@ -25,7 +25,7 @@
 
 #include "virsocketaddr.h"
 #include "virerror.h"
-#include "virutil.h"
+#include "virstring.h"
 
 #include <netdb.h>
 
index d3e1a0262bd5beea9b3e43b19936d9964c1b89fb..60b72dc0e80ef1df4710ca1b0806b1d85384af26 100644 (file)
@@ -34,7 +34,6 @@
 
 # include "virerror.h"
 # include "datatypes.h"
-# include "virutil.h"
 # include "virstatslinux.h"
 # include "viralloc.h"
 # include "virfile.h"
index aabb5c8e2afd5947152efbe3551ab804de2409b2..c7bb85a86d4ec15e7850a243ea9b49df63fbdea1 100644 (file)
@@ -43,6 +43,8 @@
 #include "vircommand.h"
 #include "virhash.h"
 #include "virendian.h"
+#include "virstring.h"
+#include "virutil.h"
 
 #define VIR_FROM_THIS VIR_FROM_STORAGE
 
index 122ebb8f0f284627fa19d2f3fe46c2b34205a85e..9b4cb0141b591db90b70eff0bcb63403e6eca023 100644 (file)
 
 #include <config.h>
 
+#include <stdlib.h>
+#include <stdio.h>
+
+#include "c-ctype.h"
 #include "virstring.h"
 #include "viralloc.h"
 #include "virbuffer.h"
@@ -180,3 +184,334 @@ virStringArrayHasString(char **strings, const char *needle)
 
     return false;
 }
+
+/* Like strtol, but produce an "int" result, and check more carefully.
+   Return 0 upon success;  return -1 to indicate failure.
+   When END_PTR is NULL, the byte after the final valid digit must be NUL.
+   Otherwise, it's like strtol and lets the caller check any suffix for
+   validity.  This function is careful to return -1 when the string S
+   represents a number that is not representable as an "int". */
+int
+virStrToLong_i(char const *s, char **end_ptr, int base, int *result)
+{
+    long int val;
+    char *p;
+    int err;
+
+    errno = 0;
+    val = strtol(s, &p, base); /* exempt from syntax-check */
+    err = (errno || (!end_ptr && *p) || p == s || (int) val != val);
+    if (end_ptr)
+        *end_ptr = p;
+    if (err)
+        return -1;
+    *result = val;
+    return 0;
+}
+
+/* Just like virStrToLong_i, above, but produce an "unsigned int" value.  */
+int
+virStrToLong_ui(char const *s, char **end_ptr, int base, unsigned int *result)
+{
+    unsigned long int val;
+    char *p;
+    int err;
+
+    errno = 0;
+    val = strtoul(s, &p, base); /* exempt from syntax-check */
+    err = (errno || (!end_ptr && *p) || p == s || (unsigned int) val != val);
+    if (end_ptr)
+        *end_ptr = p;
+    if (err)
+        return -1;
+    *result = val;
+    return 0;
+}
+
+/* Just like virStrToLong_i, above, but produce a "long" value.  */
+int
+virStrToLong_l(char const *s, char **end_ptr, int base, long *result)
+{
+    long int val;
+    char *p;
+    int err;
+
+    errno = 0;
+    val = strtol(s, &p, base); /* exempt from syntax-check */
+    err = (errno || (!end_ptr && *p) || p == s);
+    if (end_ptr)
+        *end_ptr = p;
+    if (err)
+        return -1;
+    *result = val;
+    return 0;
+}
+
+/* Just like virStrToLong_i, above, but produce an "unsigned long" value.  */
+int
+virStrToLong_ul(char const *s, char **end_ptr, int base, unsigned long *result)
+{
+    unsigned long int val;
+    char *p;
+    int err;
+
+    errno = 0;
+    val = strtoul(s, &p, base); /* exempt from syntax-check */
+    err = (errno || (!end_ptr && *p) || p == s);
+    if (end_ptr)
+        *end_ptr = p;
+    if (err)
+        return -1;
+    *result = val;
+    return 0;
+}
+
+/* Just like virStrToLong_i, above, but produce a "long long" value.  */
+int
+virStrToLong_ll(char const *s, char **end_ptr, int base, long long *result)
+{
+    long long val;
+    char *p;
+    int err;
+
+    errno = 0;
+    val = strtoll(s, &p, base); /* exempt from syntax-check */
+    err = (errno || (!end_ptr && *p) || p == s);
+    if (end_ptr)
+        *end_ptr = p;
+    if (err)
+        return -1;
+    *result = val;
+    return 0;
+}
+
+/* Just like virStrToLong_i, above, but produce an "unsigned long long" value.  */
+int
+virStrToLong_ull(char const *s, char **end_ptr, int base, unsigned long long *result)
+{
+    unsigned long long val;
+    char *p;
+    int err;
+
+    errno = 0;
+    val = strtoull(s, &p, base); /* exempt from syntax-check */
+    err = (errno || (!end_ptr && *p) || p == s);
+    if (end_ptr)
+        *end_ptr = p;
+    if (err)
+        return -1;
+    *result = val;
+    return 0;
+}
+
+int
+virStrToDouble(char const *s,
+               char **end_ptr,
+               double *result)
+{
+    double val;
+    char *p;
+    int err;
+
+    errno = 0;
+    val = strtod(s, &p); /* exempt from syntax-check */
+    err = (errno || (!end_ptr && *p) || p == s);
+    if (end_ptr)
+        *end_ptr = p;
+    if (err)
+        return -1;
+    *result = val;
+    return 0;
+}
+
+/**
+ * virVasprintf
+ *
+ * like glibc's vasprintf but makes sure *strp == NULL on failure
+ */
+int
+virVasprintf(char **strp, const char *fmt, va_list list)
+{
+    int ret;
+
+    if ((ret = vasprintf(strp, fmt, list)) == -1)
+        *strp = NULL;
+
+    return ret;
+}
+
+/**
+ * virAsprintf
+ *
+ * like glibc's_asprintf but makes sure *strp == NULL on failure
+ */
+int
+virAsprintf(char **strp, const char *fmt, ...)
+{
+    va_list ap;
+    int ret;
+
+    va_start(ap, fmt);
+    ret = virVasprintf(strp, fmt, ap);
+    va_end(ap);
+    return ret;
+}
+
+/**
+ * virStrncpy
+ *
+ * A safe version of strncpy.  The last parameter is the number of bytes
+ * available in the destination string, *not* the number of bytes you want
+ * to copy.  If the destination is not large enough to hold all n of the
+ * src string bytes plus a \0, NULL is returned and no data is copied.
+ * If the destination is large enough to hold the n bytes plus \0, then the
+ * string is copied and a pointer to the destination string is returned.
+ */
+char *
+virStrncpy(char *dest, const char *src, size_t n, size_t destbytes)
+{
+    char *ret;
+
+    if (n > (destbytes - 1))
+        return NULL;
+
+    ret = strncpy(dest, src, n);
+    /* strncpy NULL terminates iff the last character is \0.  Therefore
+     * force the last byte to be \0
+     */
+    dest[n] = '\0';
+
+    return ret;
+}
+
+/**
+ * virStrcpy
+ *
+ * A safe version of strcpy.  The last parameter is the number of bytes
+ * available in the destination string, *not* the number of bytes you want
+ * to copy.  If the destination is not large enough to hold all n of the
+ * src string bytes plus a \0, NULL is returned and no data is copied.
+ * If the destination is large enough to hold the source plus \0, then the
+ * string is copied and a pointer to the destination string is returned.
+ */
+char *
+virStrcpy(char *dest, const char *src, size_t destbytes)
+{
+    return virStrncpy(dest, src, strlen(src), destbytes);
+}
+
+/**
+ * virSkipSpaces:
+ * @str: pointer to the char pointer used
+ *
+ * Skip potential blanks, this includes space tabs, line feed,
+ * carriage returns.
+ */
+void
+virSkipSpaces(const char **str)
+{
+    const char *cur = *str;
+
+    while (c_isspace(*cur))
+        cur++;
+    *str = cur;
+}
+
+/**
+ * virSkipSpacesAndBackslash:
+ * @str: pointer to the char pointer used
+ *
+ * Like virSkipSpaces, but also skip backslashes erroneously emitted
+ * by xend
+ */
+void
+virSkipSpacesAndBackslash(const char **str)
+{
+    const char *cur = *str;
+
+    while (c_isspace(*cur) || *cur == '\\')
+        cur++;
+    *str = cur;
+}
+
+/**
+ * virTrimSpaces:
+ * @str: string to modify to remove all trailing spaces
+ * @endp: track the end of the string
+ *
+ * If @endp is NULL on entry, then all spaces prior to the trailing
+ * NUL in @str are removed, by writing NUL into the appropriate
+ * location.  If @endp is non-NULL but points to a NULL pointer,
+ * then all spaces prior to the trailing NUL in @str are removed,
+ * NUL is written to the new string end, and endp is set to the
+ * location of the (new) string end.  If @endp is non-NULL and
+ * points to a non-NULL pointer, then that pointer is used as
+ * the end of the string, endp is set to the (new) location, but
+ * no NUL pointer is written into the string.
+ */
+void
+virTrimSpaces(char *str, char **endp)
+{
+    char *end;
+
+    if (!endp || !*endp)
+        end = str + strlen(str);
+    else
+        end = *endp;
+    while (end > str && c_isspace(end[-1]))
+        end--;
+    if (endp) {
+        if (!*endp)
+            *end = '\0';
+        *endp = end;
+    } else {
+        *end = '\0';
+    }
+}
+
+/**
+ * virSkipSpacesBackwards:
+ * @str: start of string
+ * @endp: on entry, *endp must be NULL or a location within @str, on exit,
+ * will be adjusted to skip trailing spaces, or to NULL if @str had nothing
+ * but spaces.
+ */
+void
+virSkipSpacesBackwards(const char *str, char **endp)
+{
+    /* Casting away const is safe, since virTrimSpaces does not
+     * modify string with this particular usage.  */
+    char *s = (char*) str;
+
+    if (!*endp)
+        *endp = s + strlen(s);
+    virTrimSpaces(s, endp);
+    if (s == *endp)
+        *endp = NULL;
+}
+
+char *
+virArgvToString(const char *const *argv)
+{
+    int len, i;
+    char *ret, *p;
+
+    for (len = 1, i = 0; argv[i]; i++)
+        len += strlen(argv[i]) + 1;
+
+    if (VIR_ALLOC_N(ret, len) < 0)
+        return NULL;
+    p = ret;
+
+    for (i = 0; argv[i]; i++) {
+        if (i != 0)
+            *(p++) = ' ';
+
+        strcpy(p, argv[i]);
+        p += strlen(argv[i]);
+    }
+
+    *p = '\0';
+
+    return ret;
+}
index 2ceadc6b84482913498cde72f659c8bbea6ea318..457caa2fb51ca48926ec106052ea8d410505efa4 100644 (file)
@@ -22,6 +22,8 @@
 #ifndef __VIR_STRING_H__
 # define __VIR_STRING_H__
 
+# include <stdarg.h>
+
 # include "internal.h"
 
 char **virStringSplit(const char *string,
@@ -37,4 +39,52 @@ void virStringFreeList(char **strings);
 
 bool virStringArrayHasString(char **strings, const char *needle);
 
+char *virArgvToString(const char *const *argv);
+
+int virStrToLong_i(char const *s,
+                   char **end_ptr,
+                   int base,
+                   int *result);
+
+int virStrToLong_ui(char const *s,
+                    char **end_ptr,
+                    int base,
+                    unsigned int *result);
+int virStrToLong_l(char const *s,
+                   char **end_ptr,
+                   int base,
+                   long *result);
+int virStrToLong_ul(char const *s,
+                    char **end_ptr,
+                    int base,
+                    unsigned long *result);
+int virStrToLong_ll(char const *s,
+                    char **end_ptr,
+                    int base,
+                    long long *result);
+int virStrToLong_ull(char const *s,
+                     char **end_ptr,
+                     int base,
+                     unsigned long long *result);
+int virStrToDouble(char const *s,
+                   char **end_ptr,
+                   double *result);
+
+void virSkipSpaces(const char **str) ATTRIBUTE_NONNULL(1);
+void virSkipSpacesAndBackslash(const char **str) ATTRIBUTE_NONNULL(1);
+void virTrimSpaces(char *str, char **endp) ATTRIBUTE_NONNULL(1);
+void virSkipSpacesBackwards(const char *str, char **endp)
+    ATTRIBUTE_NONNULL(1) ATTRIBUTE_NONNULL(2);
+
+int virAsprintf(char **strp, const char *fmt, ...)
+    ATTRIBUTE_NONNULL(1) ATTRIBUTE_NONNULL(2) ATTRIBUTE_FMT_PRINTF(2, 3)
+    ATTRIBUTE_RETURN_CHECK;
+int virVasprintf(char **strp, const char *fmt, va_list list)
+    ATTRIBUTE_NONNULL(1) ATTRIBUTE_NONNULL(2) ATTRIBUTE_FMT_PRINTF(2, 0)
+    ATTRIBUTE_RETURN_CHECK;
+char *virStrncpy(char *dest, const char *src, size_t n, size_t destbytes)
+    ATTRIBUTE_RETURN_CHECK;
+char *virStrcpy(char *dest, const char *src, size_t destbytes)
+    ATTRIBUTE_RETURN_CHECK;
+# define virStrcpyStatic(dest, src) virStrcpy((dest), (src), sizeof(dest))
 #endif /* __VIR_STRING_H__ */
index ba0c245f99fc0634037514297083531686211043..2efe634957c15febc9427b7e8cfb72082f4ca83c 100644 (file)
 
 #include "virerror.h"
 #include "virsysinfo.h"
-#include "virutil.h"
 #include "virlog.h"
 #include "viralloc.h"
 #include "vircommand.h"
+#include "virstring.h"
 
 #define VIR_FROM_THIS VIR_FROM_SYSINFO
 
index b54a4e8d6bff2b8590fa76c8de939af320dcf756..37c639cbbbc3cecffad0b4c902642d61195164f1 100644 (file)
@@ -37,7 +37,6 @@
 #include <sys/time.h>
 
 #include "virtime.h"
-#include "virutil.h"
 #include "viralloc.h"
 #include "virerror.h"
 
index fbe5e9dbcc563368bbbed3f3f3343d5e3ed5ee08..b5504b573c9b8f823216d03b0315d35ba3a49c76 100644 (file)
@@ -24,7 +24,7 @@
 
 #include <sys/stat.h>
 
-#include "virutil.h"
+#include "virstring.h"
 #include "virerror.h"
 #include "virtpm.h"
 
index c19632177e1f8fbd8eb801c94ac3e98308da53d6..a9f8a33320532ec013330e5353b95cd0eea8e7c1 100644 (file)
@@ -27,6 +27,7 @@
 #include "viralloc.h"
 #include "virutil.h"
 #include "virerror.h"
+#include "virstring.h"
 
 #define VIR_FROM_THIS VIR_FROM_NONE
 
index 2888cb0c0a7e6371b49b6979ec002dd2bb450550..2a75425d74f55b4ce175c74f2ada5a9c89ceb5dd 100644 (file)
@@ -23,9 +23,9 @@
 #include "viruri.h"
 
 #include "viralloc.h"
-#include "virutil.h"
 #include "virerror.h"
 #include "virbuffer.h"
+#include "virstring.h"
 
 #define VIR_FROM_THIS VIR_FROM_URI
 
index 6e43f8efd5096071a183574c82afa008356638fe..3192634f4ef4fc49bdf6474cb6a92657a27ea6d1 100644 (file)
@@ -38,6 +38,7 @@
 #include "viralloc.h"
 #include "virutil.h"
 #include "virerror.h"
+#include "virstring.h"
 
 #define USB_SYSFS "/sys/bus/usb"
 #define USB_ID_LEN 10 /* "1234 5678" */
index b9de33c4eb929466e3ac6668546a524508e9db96..dc14c15238acb7951132b6b6f6325b1414f93ec5 100644 (file)
@@ -29,7 +29,6 @@
 #include <dirent.h>
 #include <stdio.h>
 #include <stdarg.h>
-#include <stdlib.h>
 #include <unistd.h>
 #include <fcntl.h>
 #include <errno.h>
@@ -80,7 +79,6 @@
 #include "virerror.h"
 #include "virlog.h"
 #include "virbuffer.h"
-#include "virutil.h"
 #include "virstoragefile.h"
 #include "viralloc.h"
 #include "virthread.h"
@@ -90,6 +88,7 @@
 #include "nonblocking.h"
 #include "passfd.h"
 #include "virprocess.h"
+#include "virstring.h"
 
 #ifndef NSIG
 # define NSIG 32
@@ -240,32 +239,6 @@ int virFileStripSuffix(char *str,
     return 1;
 }
 
-char *
-virArgvToString(const char *const *argv)
-{
-    int len, i;
-    char *ret, *p;
-
-    for (len = 1, i = 0; argv[i]; i++)
-        len += strlen(argv[i]) + 1;
-
-    if (VIR_ALLOC_N(ret, len) < 0)
-        return NULL;
-    p = ret;
-
-    for (i = 0; argv[i]; i++) {
-        if (i != 0)
-            *(p++) = ' ';
-
-        strcpy(p, argv[i]);
-        p += strlen(argv[i]);
-    }
-
-    *p = '\0';
-
-    return ret;
-}
-
 #ifndef WIN32
 
 int virSetInherit(int fd, bool inherit) {
@@ -1595,145 +1568,6 @@ virFileSanitizePath(const char *path)
     return cleanpath;
 }
 
-/* Like strtol, but produce an "int" result, and check more carefully.
-   Return 0 upon success;  return -1 to indicate failure.
-   When END_PTR is NULL, the byte after the final valid digit must be NUL.
-   Otherwise, it's like strtol and lets the caller check any suffix for
-   validity.  This function is careful to return -1 when the string S
-   represents a number that is not representable as an "int". */
-int
-virStrToLong_i(char const *s, char **end_ptr, int base, int *result)
-{
-    long int val;
-    char *p;
-    int err;
-
-    errno = 0;
-    val = strtol(s, &p, base); /* exempt from syntax-check */
-    err = (errno || (!end_ptr && *p) || p == s || (int) val != val);
-    if (end_ptr)
-        *end_ptr = p;
-    if (err)
-        return -1;
-    *result = val;
-    return 0;
-}
-
-/* Just like virStrToLong_i, above, but produce an "unsigned int" value.  */
-int
-virStrToLong_ui(char const *s, char **end_ptr, int base, unsigned int *result)
-{
-    unsigned long int val;
-    char *p;
-    int err;
-
-    errno = 0;
-    val = strtoul(s, &p, base); /* exempt from syntax-check */
-    err = (errno || (!end_ptr && *p) || p == s || (unsigned int) val != val);
-    if (end_ptr)
-        *end_ptr = p;
-    if (err)
-        return -1;
-    *result = val;
-    return 0;
-}
-
-/* Just like virStrToLong_i, above, but produce a "long" value.  */
-int
-virStrToLong_l(char const *s, char **end_ptr, int base, long *result)
-{
-    long int val;
-    char *p;
-    int err;
-
-    errno = 0;
-    val = strtol(s, &p, base); /* exempt from syntax-check */
-    err = (errno || (!end_ptr && *p) || p == s);
-    if (end_ptr)
-        *end_ptr = p;
-    if (err)
-        return -1;
-    *result = val;
-    return 0;
-}
-
-/* Just like virStrToLong_i, above, but produce an "unsigned long" value.  */
-int
-virStrToLong_ul(char const *s, char **end_ptr, int base, unsigned long *result)
-{
-    unsigned long int val;
-    char *p;
-    int err;
-
-    errno = 0;
-    val = strtoul(s, &p, base); /* exempt from syntax-check */
-    err = (errno || (!end_ptr && *p) || p == s);
-    if (end_ptr)
-        *end_ptr = p;
-    if (err)
-        return -1;
-    *result = val;
-    return 0;
-}
-
-/* Just like virStrToLong_i, above, but produce a "long long" value.  */
-int
-virStrToLong_ll(char const *s, char **end_ptr, int base, long long *result)
-{
-    long long val;
-    char *p;
-    int err;
-
-    errno = 0;
-    val = strtoll(s, &p, base); /* exempt from syntax-check */
-    err = (errno || (!end_ptr && *p) || p == s);
-    if (end_ptr)
-        *end_ptr = p;
-    if (err)
-        return -1;
-    *result = val;
-    return 0;
-}
-
-/* Just like virStrToLong_i, above, but produce an "unsigned long long" value.  */
-int
-virStrToLong_ull(char const *s, char **end_ptr, int base, unsigned long long *result)
-{
-    unsigned long long val;
-    char *p;
-    int err;
-
-    errno = 0;
-    val = strtoull(s, &p, base); /* exempt from syntax-check */
-    err = (errno || (!end_ptr && *p) || p == s);
-    if (end_ptr)
-        *end_ptr = p;
-    if (err)
-        return -1;
-    *result = val;
-    return 0;
-}
-
-int
-virStrToDouble(char const *s,
-               char **end_ptr,
-               double *result)
-{
-    double val;
-    char *p;
-    int err;
-
-    errno = 0;
-    val = strtod(s, &p); /* exempt from syntax-check */
-    err = (errno || (!end_ptr && *p) || p == s);
-    if (end_ptr)
-        *end_ptr = p;
-    if (err)
-        return -1;
-    *result = val;
-    return 0;
-}
-
 /* Convert C from hexadecimal character to integer.  */
 int
 virHexToBin(unsigned char c)
@@ -1819,95 +1653,6 @@ virScaleInteger(unsigned long long *value, const char *suffix,
     return 0;
 }
 
-/**
- * virSkipSpaces:
- * @str: pointer to the char pointer used
- *
- * Skip potential blanks, this includes space tabs, line feed,
- * carriage returns.
- */
-void
-virSkipSpaces(const char **str)
-{
-    const char *cur = *str;
-
-    while (c_isspace(*cur))
-        cur++;
-    *str = cur;
-}
-
-/**
- * virSkipSpacesAndBackslash:
- * @str: pointer to the char pointer used
- *
- * Like virSkipSpaces, but also skip backslashes erroneously emitted
- * by xend
- */
-void
-virSkipSpacesAndBackslash(const char **str)
-{
-    const char *cur = *str;
-
-    while (c_isspace(*cur) || *cur == '\\')
-        cur++;
-    *str = cur;
-}
-
-/**
- * virTrimSpaces:
- * @str: string to modify to remove all trailing spaces
- * @endp: track the end of the string
- *
- * If @endp is NULL on entry, then all spaces prior to the trailing
- * NUL in @str are removed, by writing NUL into the appropriate
- * location.  If @endp is non-NULL but points to a NULL pointer,
- * then all spaces prior to the trailing NUL in @str are removed,
- * NUL is written to the new string end, and endp is set to the
- * location of the (new) string end.  If @endp is non-NULL and
- * points to a non-NULL pointer, then that pointer is used as
- * the end of the string, endp is set to the (new) location, but
- * no NUL pointer is written into the string.
- */
-void
-virTrimSpaces(char *str, char **endp)
-{
-    char *end;
-
-    if (!endp || !*endp)
-        end = str + strlen(str);
-    else
-        end = *endp;
-    while (end > str && c_isspace(end[-1]))
-        end--;
-    if (endp) {
-        if (!*endp)
-            *end = '\0';
-        *endp = end;
-    } else {
-        *end = '\0';
-    }
-}
-
-/**
- * virSkipSpacesBackwards:
- * @str: start of string
- * @endp: on entry, *endp must be NULL or a location within @str, on exit,
- * will be adjusted to skip trailing spaces, or to NULL if @str had nothing
- * but spaces.
- */
-void
-virSkipSpacesBackwards(const char *str, char **endp)
-{
-    /* Casting away const is safe, since virTrimSpaces does not
-     * modify string with this particular usage.  */
-    char *s = (char*) str;
-
-    if (!*endp)
-        *endp = s + strlen(s);
-    virTrimSpaces(s, endp);
-    if (s == *endp)
-        *endp = NULL;
-}
 
 /**
  * virParseNumber:
@@ -1940,7 +1685,6 @@ virParseNumber(const char **str)
     return ret;
 }
 
-
 /**
  * virParseVersionString:
  * @str: const char pointer to the version string
@@ -1987,82 +1731,6 @@ virParseVersionString(const char *str, unsigned long *version,
     return 0;
 }
 
-/**
- * virVasprintf
- *
- * like glibc's vasprintf but makes sure *strp == NULL on failure
- */
-int
-virVasprintf(char **strp, const char *fmt, va_list list)
-{
-    int ret;
-
-    if ((ret = vasprintf(strp, fmt, list)) == -1)
-        *strp = NULL;
-
-    return ret;
-}
-
-/**
- * virAsprintf
- *
- * like glibc's_asprintf but makes sure *strp == NULL on failure
- */
-int
-virAsprintf(char **strp, const char *fmt, ...)
-{
-    va_list ap;
-    int ret;
-
-    va_start(ap, fmt);
-    ret = virVasprintf(strp, fmt, ap);
-    va_end(ap);
-    return ret;
-}
-
-/**
- * virStrncpy
- *
- * A safe version of strncpy.  The last parameter is the number of bytes
- * available in the destination string, *not* the number of bytes you want
- * to copy.  If the destination is not large enough to hold all n of the
- * src string bytes plus a \0, NULL is returned and no data is copied.
- * If the destination is large enough to hold the n bytes plus \0, then the
- * string is copied and a pointer to the destination string is returned.
- */
-char *
-virStrncpy(char *dest, const char *src, size_t n, size_t destbytes)
-{
-    char *ret;
-
-    if (n > (destbytes - 1))
-        return NULL;
-
-    ret = strncpy(dest, src, n);
-    /* strncpy NULL terminates iff the last character is \0.  Therefore
-     * force the last byte to be \0
-     */
-    dest[n] = '\0';
-
-    return ret;
-}
-
-/**
- * virStrcpy
- *
- * A safe version of strcpy.  The last parameter is the number of bytes
- * available in the destination string, *not* the number of bytes you want
- * to copy.  If the destination is not large enough to hold all n of the
- * src string bytes plus a \0, NULL is returned and no data is copied.
- * If the destination is large enough to hold the source plus \0, then the
- * string is copied and a pointer to the destination string is returned.
- */
-char *
-virStrcpy(char *dest, const char *src, size_t destbytes)
-{
-    return virStrncpy(dest, src, strlen(src), destbytes);
-}
-
 int virEnumFromString(const char *const*types,
                       unsigned int ntypes,
                       const char *type)
index 39033db780c9bea4cf786b6af7cda7d7400fca2e..8a2d25cdad0e4ead5ffc43ebc1f91742980a8fa0 100644 (file)
@@ -30,7 +30,6 @@
 # include <unistd.h>
 # include <sys/select.h>
 # include <sys/types.h>
-# include <stdarg.h>
 
 # ifndef MIN
 #  define MIN(a, b) ((a) < (b) ? (a) : (b))
@@ -155,63 +154,15 @@ int virFileOpenTty(int *ttymaster,
                    char **ttyName,
                    int rawmode);
 
-char *virArgvToString(const char *const *argv);
-
-int virStrToLong_i(char const *s,
-                     char **end_ptr,
-                     int base,
-                     int *result);
-
-int virStrToLong_ui(char const *s,
-                    char **end_ptr,
-                    int base,
-                    unsigned int *result);
-int virStrToLong_l(char const *s,
-                   char **end_ptr,
-                   int base,
-                   long *result);
-int virStrToLong_ul(char const *s,
-                    char **end_ptr,
-                    int base,
-                    unsigned long *result);
-int virStrToLong_ll(char const *s,
-                    char **end_ptr,
-                    int base,
-                    long long *result);
-int virStrToLong_ull(char const *s,
-                     char **end_ptr,
-                     int base,
-                     unsigned long long *result);
-int virStrToDouble(char const *s,
-                   char **end_ptr,
-                   double *result);
-
 int virScaleInteger(unsigned long long *value, const char *suffix,
                     unsigned long long scale, unsigned long long limit)
     ATTRIBUTE_NONNULL(1) ATTRIBUTE_RETURN_CHECK;
 
 int virHexToBin(unsigned char c);
 
-void virSkipSpaces(const char **str) ATTRIBUTE_NONNULL(1);
-void virSkipSpacesAndBackslash(const char **str) ATTRIBUTE_NONNULL(1);
-void virTrimSpaces(char *str, char **endp) ATTRIBUTE_NONNULL(1);
-void virSkipSpacesBackwards(const char *str, char **endp)
-    ATTRIBUTE_NONNULL(1) ATTRIBUTE_NONNULL(2);
-
 int virParseNumber(const char **str);
 int virParseVersionString(const char *str, unsigned long *version,
                           bool allowMissing);
-int virAsprintf(char **strp, const char *fmt, ...)
-    ATTRIBUTE_NONNULL(1) ATTRIBUTE_NONNULL(2) ATTRIBUTE_FMT_PRINTF(2, 3)
-    ATTRIBUTE_RETURN_CHECK;
-int virVasprintf(char **strp, const char *fmt, va_list list)
-    ATTRIBUTE_NONNULL(1) ATTRIBUTE_NONNULL(2) ATTRIBUTE_FMT_PRINTF(2, 0)
-    ATTRIBUTE_RETURN_CHECK;
-char *virStrncpy(char *dest, const char *src, size_t n, size_t destbytes)
-    ATTRIBUTE_RETURN_CHECK;
-char *virStrcpy(char *dest, const char *src, size_t destbytes)
-    ATTRIBUTE_RETURN_CHECK;
-# define virStrcpyStatic(dest, src) virStrcpy((dest), (src), sizeof(dest))
 
 int virDoubleToStr(char **strp, double number)
     ATTRIBUTE_NONNULL(1) ATTRIBUTE_RETURN_CHECK;
index aa55a338748b1353457f0554d8a93d2a3641e5c7..26120b6fc865f94be73dad372443229a6e20e8fa 100644 (file)
@@ -36,6 +36,7 @@
 #include "virutil.h"
 #include "viralloc.h"
 #include "virfile.h"
+#include "virstring.h"
 
 #define VIR_FROM_THIS VIR_FROM_XML
 
index b5fb821c92cbb7712bcbd84898fd4255ed3f3b52..6cebfaf2425716d48cc148fa10275bb8a2ba3937 100644 (file)
@@ -31,7 +31,6 @@
 
 #include "internal.h"
 #include "viralloc.h"
-#include "virutil.h"
 #include "virlog.h"
 #include "virerror.h"
 #include "vbox_MSCOMGlue.h"
index 2b568e238bc908afe47de2746ed7134991f38e4d..e0b606fe4ac777c5f5ae3258b46cde4f1fc38f28 100644 (file)
@@ -41,6 +41,7 @@
 #include "virutil.h"
 #include "virlog.h"
 #include "virerror.h"
+#include "virstring.h"
 
 #define VIR_FROM_THIS VIR_FROM_VBOX
 
index dc1e8c356ee42c3aff9f7d29890fc8693910ddb1..30721fd12a922cd973fd75e852a5ee035323a3be 100644 (file)
@@ -38,7 +38,6 @@
 #include "vbox_driver.h"
 #include "vbox_glue.h"
 #include "virerror.h"
-#include "virutil.h"
 
 #define VIR_FROM_THIS VIR_FROM_VBOX
 
index 315ba9c87837d873ae229605772836c68b13073f..43ddac8a6124d7c848245081a1205d82a240e2b9 100644 (file)
@@ -57,6 +57,7 @@
 #include "virfile.h"
 #include "fdstream.h"
 #include "viruri.h"
+#include "virstring.h"
 
 /* This one changes from version to version. */
 #if VBOX_API_VERSION == 2002
index 573fb336ad9fe2e71f315ddccaa70050be85fc45..4fb61a8a5aa1329f5fdc279df876cde682fb0fe8 100644 (file)
@@ -32,8 +32,8 @@
 #include "viruuid.h"
 #include "virerror.h"
 #include "vmx.h"
-
 #include "vmware_conf.h"
+#include "virstring.h"
 
 /* Free all memory associated with a vmware_driver structure */
 void
index 00852bec7d3d3e3b41c068aa1e6e1b60fabba717..1e2634eb9182f567e09fc6fd8575425102c64da0 100644 (file)
@@ -28,7 +28,6 @@
 #include "datatypes.h"
 #include "virfile.h"
 #include "viralloc.h"
-#include "virutil.h"
 #include "viruuid.h"
 #include "vircommand.h"
 #include "vmx.h"
index 87bec5beb8918e068b51e4f01243872b10a087e9..9ec02694e9c973b6507fa4d1b6e0cce196657ef2 100644 (file)
@@ -32,6 +32,7 @@
 #include "viruuid.h"
 #include "vmx.h"
 #include "viruri.h"
+#include "virstring.h"
 
 /*
 
index 9f5823cc931d64e1323e5a8ab64dd50793882942..8c18ed591fc79ce658f8cc2ae80a690acc190cc5 100644 (file)
 
 # include "virerror.h"
 # include "datatypes.h"
-# include "virutil.h"
 # include "block_stats.h"
 # include "viralloc.h"
 # include "virfile.h"
+# include "virstring.h"
 
 # define VIR_FROM_THIS VIR_FROM_STATS_LINUX
 
index 0642edb59bd47f841d8e5bf9d8b700d0faf87f7e..938205ed5d26608b1e5f19cb8e7777c8826ab1f9 100644 (file)
@@ -54,7 +54,6 @@
 # include "xen_inotify.h"
 #endif
 #include "virxml.h"
-#include "virutil.h"
 #include "viralloc.h"
 #include "node_device_conf.h"
 #include "virpci.h"
@@ -66,6 +65,7 @@
 #include "virnodesuspend.h"
 #include "nodeinfo.h"
 #include "configmake.h"
+#include "virstring.h"
 
 #define VIR_FROM_THIS VIR_FROM_XEN
 #define XEN_SAVE_DIR LOCALSTATEDIR "/lib/libvirt/xen/save"
index 9dbbe0745b36419b0123add53e7b82b2cdbbedcf..e15f7f2e1f274ccb52b99dbdad275bca7932ea85 100644 (file)
@@ -65,7 +65,6 @@
 #include "virlog.h"
 #include "datatypes.h"
 #include "driver.h"
-#include "virutil.h"
 #include "xen_driver.h"
 #include "xen_hypervisor.h"
 #include "xs_internal.h"
@@ -80,6 +79,7 @@
 #include "virnodesuspend.h"
 #include "virtypedparam.h"
 #include "virendian.h"
+#include "virstring.h"
 
 #define VIR_FROM_THIS VIR_FROM_XEN
 
index 860bf11dcd02da829b95d074052556691ac80da8..97f44abe4abc59e31659a488920006f1f9692340 100644 (file)
@@ -34,7 +34,6 @@
 #include "datatypes.h"
 #include "xend_internal.h"
 #include "driver.h"
-#include "virutil.h"
 #include "virsexpr.h"
 #include "xen_sxpr.h"
 #include "virbuffer.h"
@@ -47,6 +46,7 @@
 #include "virfile.h"
 #include "viruri.h"
 #include "device_conf.h"
+#include "virstring.h"
 
 /* required for cpumap_t */
 #include <xen/dom0_ops.h>
index 8ac7cb0571e7b3c6dd400695e71a524aa86d6290..921c66aebac0f478a903e2822e31041e1571fb6b 100644 (file)
 #include "virhash.h"
 #include "virbuffer.h"
 #include "viruuid.h"
-#include "virutil.h"
 #include "viralloc.h"
 #include "virlog.h"
 #include "count-one-bits.h"
+#include "virstring.h"
 
 #define VIR_FROM_THIS VIR_FROM_XENXM
 
index 1135c4e673b4404e7ed261253062662639c12aa2..7e64df690e644da584e99d18515eab547856a7e1 100644 (file)
@@ -31,7 +31,6 @@
 #include "virerror.h"
 #include "datatypes.h"
 #include "virauth.h"
-#include "virutil.h"
 #include "viruuid.h"
 #include "viralloc.h"
 #include "virbuffer.h"
@@ -39,6 +38,7 @@
 #include "xenapi_driver.h"
 #include "xenapi_driver_private.h"
 #include "xenapi_utils.h"
+#include "virstring.h"
 
 #define VIR_FROM_THIS VIR_FROM_XENAPI
 
index 3b8384eb92f8a2555aa66022c8ffc1d3122673b6..55fbb242e919cf1b1372b4419bee7b0ad0a88721 100644 (file)
@@ -29,7 +29,6 @@
 #include "domain_conf.h"
 #include "virerror.h"
 #include "datatypes.h"
-#include "virutil.h"
 #include "viruuid.h"
 #include "viralloc.h"
 #include "virbuffer.h"
@@ -37,6 +36,7 @@
 #include "viruri.h"
 #include "xenapi_driver_private.h"
 #include "xenapi_utils.h"
+#include "virstring.h"
 
 void
 xenSessionFree(xen_session *session)
index 76e57ee685d0bfec95863ef46d1badee16eaf46e..9a76d0462c02d10f5ae5570406d981e54b7e1233 100644 (file)
@@ -37,6 +37,7 @@
 #include "xenxs_private.h"
 #include "xen_sxpr.h"
 #include "virstoragefile.h"
+#include "virstring.h"
 
 /* Get a domain id from a S-expression string */
 int xenGetDomIdFromSxprString(const char *sexpr, int xendConfigVersion)
index 275e6ede58a61937e56c965c74a29cd3e8de06cf..57ce2e714fc57e69bfc4e5dec17ad61e66642e72 100644 (file)
@@ -38,6 +38,7 @@
 #include "xen_sxpr.h"
 #include "domain_conf.h"
 #include "virstoragefile.h"
+#include "virstring.h"
 
 /* Convenience method to grab a long int from the config file object */
 static int xenXMConfigGetBool(virConfPtr conf,
index ac369f97f77be8eb02677d196eb8659a589a4524..6cb88c5072ff3e5b91a87aeada84b2e7edd0cb42 100644 (file)
 #include "testutils.h"
 #include "internal.h"
 #include "nodeinfo.h"
-#include "virutil.h"
 #include "viralloc.h"
 #include "vircommand.h"
 #include "virfile.h"
 #include "virpidfile.h"
 #include "virerror.h"
 #include "virthread.h"
+#include "virstring.h"
 
 #define VIR_FROM_THIS VIR_FROM_NONE
 
index ab96824b98d0334aa97edf7f7c89783c7a70cf1c..01054407726f2572b2bda125789afb26fcfc6d13 100644 (file)
@@ -38,6 +38,7 @@
 #include "cpu_conf.h"
 #include "cpu/cpu.h"
 #include "cpu/cpu_map.h"
+#include "virstring.h"
 
 static const char *abs_top_srcdir;
 
index 694c382f59a46e9446a150aff275b3f2cb914066..9eddf458fe2c10353254e7f3258ec26155b729e8 100644 (file)
@@ -16,6 +16,7 @@
 # include "qemu/qemu_conf.h"
 # include "qemu/qemu_domain.h"
 # include "testutilsqemu.h"
+# include "virstring.h"
 
 static virQEMUDriver driver;
 
index e2baea2146295775944452dcf8a52552bb083388..bb58a3ab287dde33c82606b7cdfa59cc141f2b23 100644 (file)
@@ -10,7 +10,6 @@
 
 # include "internal.h"
 # include "viralloc.h"
-# include "virutil.h"
 # include "vmx/vmx.h"
 # include "esx/esx_util.h"
 # include "esx/esx_vi_types.h"
index f969fa1782318f7eb30b0a6b272145a2c2644668..9d86198bcbc706de2da3a6e8ae020b39bddc9b48 100644 (file)
@@ -12,7 +12,7 @@
 #include "testutils.h"
 #include "interface_conf.h"
 #include "testutilsqemu.h"
-
+#include "virstring.h"
 
 static int
 testCompareXMLToXMLFiles(const char *xml)
index 01e94153c6ecef54525706e1a2a37ea08a3fd13d..df8d3d8dbcac6d7a469f2a8449cb9a43f7d5b8b6 100644 (file)
@@ -29,6 +29,7 @@
 #include "virerror.h"
 #include "virlog.h"
 #include "virconf.h"
+#include "virstring.h"
 
 #define VIR_FROM_THIS VIR_FROM_NONE
 
index 4870f4282bc26dcf21515b5e529662ae496a5798..827c2fd267761ff5f359b5777c41f7a1b661a01d 100644 (file)
@@ -15,6 +15,7 @@
 # include "internal.h"
 # include "lxc/lxc_conf.h"
 # include "testutilslxc.h"
+# include "virstring.h"
 
 static virCapsPtr caps;
 static virDomainXMLOptionPtr xmlopt;
index 88016ee1195b3cbab7dc7b82dfebb1b76adda71d..520febacef81daca9f4b65f9418d199894f37765 100644 (file)
@@ -14,6 +14,7 @@
 #include "vircommand.h"
 #include "viralloc.h"
 #include "network/bridge_driver.h"
+#include "virstring.h"
 
 static int
 testCompareXMLToConfFiles(const char *inxml, const char *outconf, dnsmasqCapsPtr caps)
index 1063435651e693732ad045f77f7562e1f9b439d8..5eca143ccce2a8cd14ed4fba3acca774ccada85c 100644 (file)
@@ -12,6 +12,7 @@
 #include "testutils.h"
 #include "network_conf.h"
 #include "testutilsqemu.h"
+#include "virstring.h"
 
 static int
 testCompareXMLToXMLFiles(const char *inxml, const char *outxml,
index 38f2e9a027d976bcb29f9cc30dca08ba8376a417..e81c61797412f76ff352cc6b04840729046c129a 100644 (file)
@@ -12,6 +12,7 @@
 #include "testutils.h"
 #include "node_device_conf.h"
 #include "testutilsqemu.h"
+#include "virstring.h"
 
 static int
 testCompareXMLToXMLFiles(const char *xml)
index d900eb9ae9f77a379d3006248dba823fbbe70219..733d350a2f6aec9d148b7798fcc8eb7ad51f0285 100644 (file)
@@ -8,8 +8,8 @@
 #include "testutils.h"
 #include "internal.h"
 #include "nodeinfo.h"
-#include "virutil.h"
 #include "virfile.h"
+#include "virstring.h"
 
 #if ! (defined __linux__  &&  (defined(__x86_64__) || \
                                defined(__amd64__)  || \
index a215bf8ab7bde98e1dd8cd70262fe7965dd846d1..158bc9f4ce1071971b53846d22334bb54d8ee4a8 100644 (file)
@@ -15,6 +15,7 @@
 #include "nwfilter_params.h"
 #include "nwfilter_conf.h"
 #include "testutilsqemu.h"
+#include "virstring.h"
 
 static int
 testCompareXMLToXMLFiles(const char *inxml, const char *outxml,
index 616b6be06385c457e80fd8fe44d89b7860c5866b..be0c74cbd53b7cb65ad91359e1c69f349156faaa 100644 (file)
@@ -10,8 +10,8 @@
 
 # include "internal.h"
 # include "viralloc.h"
-# include "virutil.h"
 # include "openvz/openvz_conf.h"
+# include "virstring.h"
 
 static int
 testLocateConfFile(int vpsid ATTRIBUTE_UNUSED, char **conffile,
index 9f1bb242d873a342c239d6459fd4bb01abc392e3..005aa0cfe83dc107b3a532cb66e540c57d06394c 100644 (file)
@@ -14,8 +14,8 @@
 
 # include "internal.h"
 # include "qemu/qemu_command.h"
-
 # include "testutilsqemu.h"
+# include "virstring.h"
 
 static virQEMUDriver driver;
 
index eeba4d42011a03e3d33e0df44c23d49dd0832a39..fa56406f4650be907d688739aa2cbcfcad3229bf 100644 (file)
@@ -9,6 +9,7 @@
 
 # include "qemu/qemu_capabilities.h"
 # include "viralloc.h"
+# include "virstring.h"
 
 struct testInfo {
     const char *name;
index a8fc57ac711e2b0e3c4e8c65c5824cd6b8c5fc89..61ac2d69f1917f2f0d7a9a4142dd40810da88e37 100644 (file)
@@ -11,7 +11,6 @@
 
 # include "internal.h"
 # include "viralloc.h"
-# include "virutil.h"
 # include "qemu/qemu_monitor.h"
 
 struct testEscapeString
index 43e7cb904a9500ac427f7ff2d0195ba7e6c82c93..c24a37fb99f3dec6b84343f065b398abd413c19e 100644 (file)
@@ -30,9 +30,9 @@
 #include "qemu/qemu_monitor.h"
 #include "rpc/virnetsocket.h"
 #include "viralloc.h"
-#include "virutil.h"
 #include "virlog.h"
 #include "virerror.h"
+#include "virstring.h"
 
 #define VIR_FROM_THIS VIR_FROM_NONE
 
index 9699f775a559496e5287a63de1c367707b783551..128627308ea09c8b883212b3f95e2c68d7834ae2 100644 (file)
@@ -19,6 +19,7 @@
 # include "qemu/qemu_domain.h"
 # include "datatypes.h"
 # include "cpu/cpu_map.h"
+# include "virstring.h"
 
 # include "testutilsqemu.h"
 
index a81cfcf364976de6eb4a6038726c9690c4758a29..64c1c83023d9bd8778ddd12ace861696b6526623 100644 (file)
@@ -16,6 +16,7 @@
 # include "qemu/qemu_conf.h"
 # include "qemu/qemu_domain.h"
 # include "testutilsqemu.h"
+# include "virstring.h"
 
 static virQEMUDriver driver;
 
index 4e9144befc6c5b53e87106fe3911694b63236e20..cd493e37e1bad227992f8a07fa50d7125bde8eef 100644 (file)
@@ -18,8 +18,8 @@
 # include "qemu/qemu_domain.h"
 # include "datatypes.h"
 # include "cpu/cpu_map.h"
-
 # include "testutilsqemu.h"
+# include "virstring.h"
 
 static const char *abs_top_srcdir;
 static virQEMUDriver driver;
index f585f6fad539b05819c5e23e4f643f61919cdeb7..e270a765c3a67de6b07e85c63efb6917b99a100b 100644 (file)
@@ -37,9 +37,8 @@
 #include "virerror.h"
 #include "virfile.h"
 #include "virlog.h"
-#include "virutil.h"
 #include "security/security_manager.h"
-
+#include "virstring.h"
 
 #define VIR_FROM_THIS VIR_FROM_NONE
 
index da8a12f3d7d369ae0bc4d594810d68caabea6c50..dd4cd11270ac1a93ef8ad735a1cf11d978777109 100644 (file)
 #include "internal.h"
 #include "testutils.h"
 #include "viralloc.h"
-#include "virutil.h"
 #include "virlog.h"
 #include "virerror.h"
 #include "security/security_manager.h"
-
+#include "virstring.h"
 
 #define VIR_FROM_THIS VIR_FROM_NONE
 
index b7487efe17880f9982981541105c2d6d656ac05b..f4d119e3b3f5d062885cb46d776e87ad399fda22 100644 (file)
@@ -12,6 +12,7 @@
 #include "xenxs/xen_sxpr.h"
 #include "testutils.h"
 #include "testutilsxen.h"
+#include "virstring.h"
 
 static virCapsPtr caps;
 
index 9be63c597fed9dbb9f5a189215b09334e092b1d3..0376e63b54ee62e41cfb34fa19d60b6df35373fe 100644 (file)
@@ -12,6 +12,7 @@
 #include "testutils.h"
 #include "storage_conf.h"
 #include "testutilsqemu.h"
+#include "virstring.h"
 
 static int
 testCompareXMLToXMLFiles(const char *inxml, const char *outxml)
index 77ba80050276d89ce2ce2be34797270a08f3e77b..e1507b449572d3fc559484931f267b6fde7abeb4 100644 (file)
@@ -5,6 +5,7 @@
 #include "datatypes.h"
 #include "storage/storage_backend.h"
 #include "testutilsqemu.h"
+#include "virstring.h"
 
 const char create_tool[] = "qemu-img";
 
index 0902496de560c4d7647c5902d35099067b894dba..07c79c1cdd311b65b448f37cbcfa50b12331cac1 100644 (file)
@@ -12,6 +12,7 @@
 #include "testutils.h"
 #include "storage_conf.h"
 #include "testutilsqemu.h"
+#include "virstring.h"
 
 static int
 testCompareXMLToXMLFiles(const char *poolxml, const char *inxml,
index 895520809c069d52d256461add065a76bdc77088..dc0451b8d3d15ab5a1f28008c760b49dd9f8f845 100644 (file)
@@ -33,8 +33,8 @@
 #include "virbuffer.h"
 #include "virsysinfo.h"
 #include "testutils.h"
-#include "virutil.h"
 #include "virfile.h"
+#include "virstring.h"
 
 #if defined (__linux__)
 
index 0fb69ec928f7b1393deb9385b994daa53eae54ad..b0806defb8ea8a8675bffad8aa74bab7c864cce3 100644 (file)
@@ -45,6 +45,7 @@
 #include "virrandom.h"
 #include "dirname.h"
 #include "virprocess.h"
+#include "virstring.h"
 
 #if TEST_OOM_TRACE
 # include <execinfo.h>
index 67c5de817d570bc99caacf2e7caa7bc310afec96..a27bae55396c9da31bf91e7a48e0dbf13cae5212 100644 (file)
@@ -24,7 +24,6 @@
 #include <signal.h>
 
 #include "testutils.h"
-#include "virutil.h"
 #include "virerror.h"
 #include "viralloc.h"
 #include "virlog.h"
index 7f9ee665bf5b9aa96c3e43db7d8131dcb7b0d161..c7a504b2f1f42d5383d07af3e3dd020e07882eb1 100644 (file)
@@ -5,10 +5,10 @@
 #include <string.h>
 
 #include "internal.h"
-#include "virutil.h"
 #include "testutils.h"
 #include "virbuffer.h"
 #include "viralloc.h"
+#include "virstring.h"
 
 #define TEST_ERROR(...)                             \
     do {                                            \
index e2adef8901273574f973b10023d8f1e81c0188e0..4777fae8473e5a504b24f01fe939ba3e3f01a1e3 100644 (file)
@@ -28,7 +28,7 @@
 
 # define __VIR_CGROUP_ALLOW_INCLUDE_PRIV_H__
 # include "vircgrouppriv.h"
-# include "virutil.h"
+# include "virstring.h"
 # include "virerror.h"
 # include "virlog.h"
 # include "virfile.h"
index bbceb966bdd58d17623603e8eadba9d5296e8ee3..1aae245af75c955c8cfe2ade1e71169ed00e8c78 100644 (file)
@@ -21,7 +21,6 @@
 #include <config.h>
 
 #include "testutils.h"
-#include "virutil.h"
 #include "virerror.h"
 #include "viralloc.h"
 #include "virlog.h"
index 6e4f2670a66dbdef39262b15b4334f60b65a2af1..f36fc76c7ce2fc92bd239bf8732e7244e540d512 100644 (file)
@@ -10,9 +10,8 @@
 #include "virhashdata.h"
 #include "testutils.h"
 #include "viralloc.h"
-#include "virutil.h"
 #include "virlog.h"
-
+#include "virstring.h"
 
 #define testError(...)                                          \
     do {                                                        \
index e8987958e8b09ec04b6ca8f0bc2adee06ee1d4d6..269a57d1379c6c49736d29312e00c5fa845c1297 100644 (file)
@@ -25,7 +25,6 @@
 #include "testutils.h"
 
 #include "viridentity.h"
-#include "virutil.h"
 #include "virerror.h"
 #include "viralloc.h"
 #include "virlog.h"
index fb41840f860d85012081627c056765b21854bec5..8fe7e38f39474c2287434237906efbf48072da06 100644 (file)
@@ -24,7 +24,6 @@
 #include <signal.h>
 
 #include "testutils.h"
-#include "virutil.h"
 #include "virerror.h"
 #include "viralloc.h"
 #include "virlog.h"
index e58fd1feeec3de21988b1e45f89c5a3e73084be5..96defe420f07d0fbb10ed5569b18f74afaf2dba0 100644 (file)
@@ -24,7 +24,6 @@
 #include <signal.h>
 
 #include "testutils.h"
-#include "virutil.h"
 #include "virerror.h"
 #include "viralloc.h"
 #include "virlog.h"
index aaa6acb6bb95e37c35e119c21f3ad4eb43f33b40..5e2925da16769c5c19f8fe4cbedbf50132e9f860 100644 (file)
@@ -33,6 +33,7 @@
 #include "viralloc.h"
 #include "virlog.h"
 #include "virfile.h"
+#include "virstring.h"
 
 #include "rpc/virnetsocket.h"
 
index 1935602c970255ccebc3fa43a35ddc930f1b63ca..a52850687d77cbbd10b2a942272cd711e4b13826 100644 (file)
@@ -54,8 +54,8 @@ int bind(int sockfd ATTRIBUTE_UNUSED,
 # include "virerror.h"
 # include "viralloc.h"
 # include "virlog.h"
-
 # include "virportallocator.h"
+# include "virstring.h"
 
 # define VIR_FROM_THIS VIR_FROM_RPC
 
index b82a4c4901f63fce43704937b31dfa2e3facc076..fad67745be3178028f232739d7168d979a6398d9 100644 (file)
@@ -6,8 +6,8 @@
 
 #include "internal.h"
 #include "virxml.h"
-#include "virutil.h"
 #include "testutils.h"
+#include "virstring.h"
 
 #ifdef WIN32
 
index 0e6ba9e75c9e9c5ed21d34939602404c5ab3850f..0016052e3385fbadb029e4c735ad362deaa380e2 100644 (file)
@@ -27,6 +27,7 @@
 #include "virerror.h"
 #include "virlog.h"
 #include "virstoragefile.h"
+#include "virstring.h"
 
 #define VIR_FROM_THIS VIR_FROM_NONE
 
index 86d8986cd7ce65f897b0d386f8df7876760ef726..db1e8a9b495dc6e09c222646f35df3ceeb382219 100644 (file)
@@ -23,7 +23,6 @@
 #include <stdlib.h>
 
 #include "testutils.h"
-#include "virutil.h"
 #include "virerror.h"
 #include "viralloc.h"
 #include "virlog.h"
index 18f621a61047ba84a76754b15bd793891e3b12a5..7768ecb265752e341a921be2d51d60409978cc27 100644 (file)
@@ -24,7 +24,6 @@
 #include <signal.h>
 
 #include "testutils.h"
-#include "virutil.h"
 #include "virerror.h"
 #include "viralloc.h"
 #include "virlog.h"
index 3cb88daee3e627183f866ad2dbba04222cbe99a0..0bcd78d560683b236ad4f81a207406b899823e92 100644 (file)
@@ -24,7 +24,6 @@
 #include <signal.h>
 
 #include "testutils.h"
-#include "virutil.h"
 #include "virerror.h"
 #include "viralloc.h"
 #include "virlog.h"
index 0003f5f4a55afbc5bf1d88466a27dd2ce4690f92..bd7cbc6a0bf4f5ac08e373fc7e7c923e43371256 100644 (file)
@@ -11,6 +11,7 @@
 # include "internal.h"
 # include "viralloc.h"
 # include "vmx/vmx.h"
+# include "virstring.h"
 
 static virCapsPtr caps;
 static virDomainXMLOptionPtr xmlopt;
index 381802ed7030517531dc1160ce4dd454efa3ffa5..e220234b6afbea0bbff76c282da58e839ad52300 100644 (file)
@@ -10,6 +10,7 @@
 #include "testutils.h"
 #include "xen/xen_hypervisor.h"
 #include "virfile.h"
+#include "virstring.h"
 
 static int
 testCompareFiles(virArch hostmachine, const char *xml_rel,
index b7ff48ca46384fb8f6784e952c5e38a500ec14b1..8e0c59e4590c3822756e256f44b18ccf2f437934 100644 (file)
@@ -35,6 +35,7 @@
 #include "testutils.h"
 #include "testutilsxen.h"
 #include "viralloc.h"
+#include "virstring.h"
 
 static virCapsPtr caps;
 static virDomainXMLOptionPtr xmlopt;
index 062ff075cd4f3508cd4899c34d16856d50e47186..ec196c41d4aded3b20298999327f02029d29d2fb 100644 (file)
@@ -14,6 +14,7 @@
 #include "xenxs/xen_sxpr.h"
 #include "testutils.h"
 #include "testutilsxen.h"
+#include "virstring.h"
 
 static virCapsPtr caps;
 static virDomainXMLOptionPtr xmlopt;
index fa4f6f9fd0ce56a6628e7038f5c5893aa3d6db09..38b5a4de49aa96a6746f9afc4357b941f702df3f 100644 (file)
@@ -11,6 +11,7 @@
 # include "internal.h"
 # include "viralloc.h"
 # include "vmx/vmx.h"
+# include "virstring.h"
 
 static virCapsPtr caps;
 static virVMXContext ctx;
index e4231347515077c81ab3f9a0bcfeab12ed0974df..9abfb584f80fd037c1fb0234ceb6cc63672fccfb 100644 (file)
@@ -39,7 +39,6 @@
 # include "internal.h"
 # include "console.h"
 # include "virlog.h"
-# include "virutil.h"
 # include "virfile.h"
 # include "viralloc.h"
 # include "virthread.h"
index f7297f5ae1d43e8fa3766305956cf34d59fae823..5ed89d1d50d7b7554507783e71b29a53e705faca 100644 (file)
@@ -38,6 +38,7 @@
 #include "virmacaddr.h"
 #include "virsh-domain.h"
 #include "virxml.h"
+#include "virstring.h"
 
 static const char *
 vshDomainIOErrorToString(int error)
index 5c8bcbaf15b5b2682379d3832eab9a7bc6dfd1e4..9ac9bd14fbb9e201e8f789d8878c038dafd1cdaf 100644 (file)
@@ -44,7 +44,6 @@
 #include "console.h"
 #include "viralloc.h"
 #include "vircommand.h"
-#include "virutil.h"
 #include "virfile.h"
 #include "virjson.h"
 #include "virkeycode.h"
index a7e31da613406851302fae24afec595d11329ca5..a75d8440e9c70d0cec301a66c772e46c20f57c1e 100644 (file)
 #include "internal.h"
 #include "virbuffer.h"
 #include "viralloc.h"
-#include "virutil.h"
 #include "virsh-domain.h"
 #include "virxml.h"
 #include "virtypedparam.h"
+#include "virstring.h"
 
 /*
  * "capabilities" command
index c022e1d2ed7f7deb70a5a4d65a639d41e756d4fa..706074faad0ccb3357488143cb7f9a1dd34ac716 100644 (file)
@@ -36,6 +36,7 @@
 #include "viralloc.h"
 #include "virutil.h"
 #include "virxml.h"
+#include "virstring.h"
 
 virInterfacePtr
 vshCommandOptInterfaceBy(vshControl *ctl, const vshCmd *cmd,
index bc1a64a991325882d53148f0721e4ee75df8dee8..81267bcaa8f3d25484eb78095e1b28e4dbdaa068 100644 (file)
@@ -34,7 +34,6 @@
 #include "internal.h"
 #include "virbuffer.h"
 #include "viralloc.h"
-#include "virutil.h"
 #include "virxml.h"
 #include "conf/network_conf.h"
 
index c196e7aeadbf4e0318bdd158077d07d50ecfdba1..8fa67fcc865cddbd4c9f432ca918864105a49c17 100644 (file)
@@ -34,7 +34,6 @@
 #include "internal.h"
 #include "virbuffer.h"
 #include "viralloc.h"
-#include "virutil.h"
 #include "virxml.h"
 #include "conf/node_device_conf.h"
 
index c1e91ea94ca0a9b4092f2ae5d93a565519344810..f154366b396999e17927f50cd5fd05913693e0af 100644 (file)
@@ -34,9 +34,9 @@
 #include "internal.h"
 #include "virbuffer.h"
 #include "viralloc.h"
-#include "virutil.h"
 #include "virxml.h"
 #include "conf/storage_conf.h"
+#include "virstring.h"
 
 virStoragePoolPtr
 vshCommandOptPoolBy(vshControl *ctl, const vshCmd *cmd, const char *optname,
index 44a1e03faaafd38304e9080fae261de9e6eec0a0..4f5fa156da51a29cc2606e3388474b4e9cbc1e7f 100644 (file)
@@ -36,7 +36,6 @@
 #include "internal.h"
 #include "virbuffer.h"
 #include "viralloc.h"
-#include "virutil.h"
 #include "virsh-domain.h"
 #include "virxml.h"
 #include "conf/snapshot_conf.h"
index 728bc23a9214283a91f2f0f37bcd1cb9378c3962..a222cca62eef7d51e80b5e25122c1097f6734211 100644 (file)
@@ -40,6 +40,7 @@
 #include "virfile.h"
 #include "virsh-pool.h"
 #include "virxml.h"
+#include "virstring.h"
 
 virStorageVolPtr
 vshCommandOptVolBy(vshControl *ctl, const vshCmd *cmd,
index ac86608a1a99798e01efb3e81322b71cda39684b..22bcec2bed0112b82bea99d5ba3a84246af6a5da 100644 (file)
@@ -57,7 +57,6 @@
 #include "base64.h"
 #include "virbuffer.h"
 #include "console.h"
-#include "virutil.h"
 #include "viralloc.h"
 #include "virxml.h"
 #include <libvirt/libvirt-qemu.h>
@@ -71,6 +70,7 @@
 #include "virbitmap.h"
 #include "conf/domain_conf.h"
 #include "virtypedparam.h"
+#include "virstring.h"
 
 #include "virsh-domain.h"
 #include "virsh-domain-monitor.h"
index 34a527f7c715bf616ade8ac767d1940ef69737d5..c17c2574d1b3081af2dab859499e94abd551fc51 100644 (file)
@@ -31,6 +31,7 @@
 #include "viralloc.h"
 #include "virfile.h"
 #include "virt-host-validate-common.h"
+#include "virstring.h"
 
 static bool quiet;