1. 11 3月, 2008 1 次提交
  2. 05 3月, 2008 1 次提交
  3. 28 2月, 2008 1 次提交
    • R
      virMacAddrCompare for comparing MAC addresses · 92a1e14b
      Richard W.M. Jones 提交于
      	* src/util.c, src/util.h, src/libvirt_sym.version: Added
      	  virMacAddrCompare utility function for comparing MAC
      	  addresses.
      	* src/virsh.c, src/xm_internal.c: Use virMacAddrCompare
      	  to compare addresses.  (Shigeki Sakamoto and Richard Jones).
      92a1e14b
  4. 22 2月, 2008 1 次提交
    • J
      Use safewrite in place of write, in many cases. · b59d9c85
      Jim Meyering 提交于
      Also add "make syntax-check" rules to ensure no new uses sneak in.
      
      There are many uses of write like this:
      
          if (write (fd, xml, towrite) != towrite)
              return -1;
      
      The problem is that the syscall can succeed, yet write less than
      the requested number of bytes, so the caller should retry
      rather than simply failing.
      
      This patch changes most of them to use util.c's safewrite wrapper,
      which encapsulates the process.  Also, there were a few cases in
      which the retry loop was open-coded, and I replaced those, too.
      
      * Makefile.maint (sc_avoid_write): New rule, to avoid recurrence.
      * .x-sc_avoid_write: New file.  Record two legitimate exemptions.
      * qemud/qemud.c (sig_handler, qemudClientWriteBuf): Use safewrite, not write.
      * src/conf.c (__virConfWriteFile): Likewise.
      * src/qemu_conf.c (qemudSaveConfig, qemudSaveNetworkConfig): Likewise.
      * src/qemu_driver.c (qemudWaitForMonitor, qemudStartVMDaemon)
      (qemudVMData, PROC_IP_FORWARD): Likewise.
      * proxy/libvirt_proxy.c: Include "util.h".
      (proxyWriteClientSocket): Use safewrite.
      * src/test.c (testDomainSave, testDomainCoreDump): Likewise.
      * src/proxy_internal.c (virProxyWriteClientSocket): Likewise.
      * src/virsh.c: Include "util-lib.h".
      (vshOutputLogFile): Use safewrite.
      * src/console.c: Include "util-lib.h".
      (vshRunConsole): Use safewrite.
      b59d9c85
  5. 20 2月, 2008 2 次提交
  6. 08 2月, 2008 2 次提交
    • M
      Fix gcc-4.3.0 "inlining failed" warning. · 3da5504e
      Mark McLoughlin 提交于
      * src/internal.h: move xstrol() variants from here ...
      
      * src/util.[ch]: ... to here and rename to virStrToLong()
      
      * src/libvirt_sym.version: export __virStrToLong_i() for
      virsh and qemud.
      
      * src/nodeinfo.c, src/stats_linux.c, src/virsh.c,
        src/xend_internal.c, qemud/qemud.c: replace xstrtol()
      calls with virStrToLong()
      
      * src/nodeinfo.h: don't include internal.h, which was only
      needed for xstrtol(), but instead include libvirt.h which
      is suffificient for the declarations in the header.
      3da5504e
    • J
      Remove more useless if tests before "free"-like functions. · e8ff93b4
      Jim Meyering 提交于
      * build-aux/useless-if-before-free: Rename from ...
      * build-aux/find-unnecessary-if-before-free: ... this.  Remove file.
      Also changed it so that new names are no longer hard-coded in the
      script.  Instead, they're supplied via options:
      * Makefile.cfg (useless_free_options): Define.
      Add xmlXPathFreeObject to the list of free-like functions it detects.
      * Makefile.maint (sc_avoid_if_before_free): Reflect script renaming.
      * .x-sc_avoid_if_before_free: Likewise.
      * src/openvz_conf.c (openvzParseXML): Remove useless "if"-before-free.
      * src/qemu_conf.c (qemudParseXML, qemudParseNetworkXML): Likewise.
      * src/virsh.c (cmdVNCDisplay, cmdTTYConsole, cmdDetachInterface):
      (cmdDetachDisk): Likewise.
      * src/xm_internal.c (xenXMConfigSetIntFromXPath): Likewise.
      (xenXMConfigSetStringFromXPath, xenXMParseXMLToConfig): Likewise.
      (xenXMDomainAttachDevice, xenXMAttachDisk, xenXMAttachInterface):
      (xenXMDomainDetachDevice): Likewise.
      * src/xml.c (virXPathString): Likewise.
      * tests/xmlrpctest.c (checkRequestValue): Likewise.
      e8ff93b4
  7. 06 2月, 2008 1 次提交
  8. 04 2月, 2008 1 次提交
  9. 31 1月, 2008 2 次提交
  10. 30 1月, 2008 3 次提交
    • J
      Also detect and remove unnecessary if-before-xmlXPathFreeContext. · 2367caa3
      Jim Meyering 提交于
      * build-aux/find-unnecessary-if-before-free: Update regexp.
      * src/openvz_conf.c: Remove unnecessary "if (P)"-before xmlXPathFreeContext.
      * src/qemu_conf.c: Likewise.
      * src/virsh.c: Likewise.
      * src/xm_internal.c: Likewise.
      * src/xml.c: Likewise.
      * tests/xmlrpctest.c: Likewise.
      2367caa3
    • J
      Enable the <config.h>-requiring test; fix violations · a3781881
      Jim Meyering 提交于
      Use <config.h>, not "config.h", per autoconf documentation.
      * Makefile.cfg (local-checks-to-skip) [sc_require_config_h]: Enable.
      * .x-sc_require_config_h: New file, to list exempted files.
      * Makefile.am (EXTRA_DIST): Add .x-sc_require_config_h.
      a3781881
    • J
      Given code like if (foo) free (foo); remove the useless "if (foo) " part. · acff2d11
      Jim Meyering 提交于
      Likewise, given if (foo != NULL) free (foo); remove the useless "if" test.
      
      * proxy/libvirt_proxy.c: Remove unnecessary "if" test before free.
      * python/generator.py: Likewise.
      * qemud/qemud.c: Likewise.
      * src/buf.c: Likewise.
      * src/conf.c: Likewise.
      * src/hash.c: Likewise.
      * src/iptables.c: Likewise.
      * src/libvirt.c: Likewise.
      * src/openvz_conf.c: Likewise.
      * src/qemu_conf.c: Likewise.
      * src/qemu_driver.c: Likewise.
      * src/remote_internal.c: Likewise.
      * src/test.c: Likewise.
      * src/virsh.c: Likewise.
      * src/virterror.c: Likewise.
      * src/xen_internal.c: Likewise.
      * src/xen_unified.c: Likewise.
      * src/xend_internal.c: Likewise.
      * src/xm_internal.c: Likewise.
      * src/xml.c: Likewise.
      * src/xmlrpc.c: Likewise.
      * src/xs_internal.c: Likewise.
      * tests/testutils.c: Likewise.
      * tests/xencapstest.c: Likewise.
      * tests/xmconfigtest.c: Likewise.
      acff2d11
  11. 21 1月, 2008 1 次提交
  12. 17 1月, 2008 1 次提交
  13. 07 12月, 2007 2 次提交
  14. 06 12月, 2007 3 次提交
  15. 05 12月, 2007 1 次提交
  16. 01 12月, 2007 1 次提交
  17. 29 11月, 2007 1 次提交
  18. 28 11月, 2007 2 次提交
  19. 12 11月, 2007 1 次提交
    • D
      Begin fixing uses of strtol: parse integers more carefully. · a500a479
      Daniel Veillard 提交于
      Patch from Jim Meyering
      * src/internal.h: Include <errno.h>.
        Define new static inline function, xstrtol_i.
      * src/virsh.c: Detect integer overflow in domain ID number
        in vshCommandOptDomainBy. Detect overflow and invalid port
        number suffix in cmdVNCDisplay.
      * src/xend_internal.c: Parse CPU number more carefully in
        xenDaemonDomainGetVcpus.
      * tests/int-overflow: New script. Test for the above-fixed bug.
      * tests/Makefile.am: Add int-overflow to TESTS. Define
        TESTS_ENVIRONMENT, to propagate $abs_top_* variables into the
        int-overflow script. Adapt the "valgrind" rule not to clobber
        new TESTS_ENVIRONMENT.
      Daniel
      a500a479
  20. 09 11月, 2007 3 次提交
  21. 06 11月, 2007 1 次提交
  22. 30 9月, 2007 2 次提交
  23. 28 9月, 2007 1 次提交
    • D
      * include/libvirt/libvirt.h[.in] src/driver.h src/openvz_driver.c · 4bf3bc9e
      Daniel Veillard 提交于
        src/qemu_driver.c src/remote_internal.c src/test.c
        src/xen_internal.[ch] src/xen_unified.c src/xend_internal.[ch]
        src/libvirt.c src/libvirt_sym.version: adding NUMA support patches
        from Beth Kon adding new virNodeGetCellsFreeMemory entry point
        and extending the virConnectGetCapabilities one. Fix a couple of
        issues in the patch and add to exported symbols from shared lib.
      * docs/virsh.pod docs/virsh.1 src/virsh.c: added new command
        freecell to get the available memory on the node or in a NUMA cell.
      * docs/*: updated and regenerated the documentation
      Daniel
      4bf3bc9e
  24. 29 8月, 2007 1 次提交
  25. 21 8月, 2007 3 次提交
    • D
      * src/xs_internal.c: cleanup of memory leaks from Masayuki Sunou · 3a4c8d21
      Daniel Veillard 提交于
      * src/virsh.c: another memory leaks of virsh schedinfo cleanup from
        Saori Fukuta
      * po/*: string localization merge/update
      Daniel
      3a4c8d21
    • R
      Tue Aug 21 10:58:00 BST 2007 Richard W.M. Jones <rjones@redhat.com> · 442a1577
      Richard W.M. Jones 提交于
      	* src/libvirt.c (virDomainBlockStats, virDomainInterfaceStats):
      	  Added block device and network interface statistics.
      	* src/xen_internal.c: Support for stats from Xen domains.
      	* qemud/remote.c, qemud/remote_protocol.x, qemud/remote_internal.c:
      	  Support for fetching device and network interface stats
      	  across remote connections.
      	* src/virsh.c: Added 'virsh domblkstat' and 'virsh domifstat'
      	  commands to display stats.
      	* docs/libvir.html, docs/hvsupport.html: Updated hvsupport
      	  documentation.
      442a1577
    • R
      Tue Aug 21 10:21:00 BST 2007 Richard W.M. Jones <rjones@redhat.com> · 81005437
      Richard W.M. Jones 提交于
      	* src/libvirt.c (virDomainMigrate): Added virDomainMigrate
      	  API call.
      	* src/xend_internal.c, src/xen_unified.c: Support for migration
      	  of Xen domains.
      	* src/xen_internal.c: Xen capabilities indicates level of
      	  support for migration.
      	* qemud/remote.c, qemud/remote_protocol.x, src/remote_internal.c:
      	  Support for migration between remote hypervisors.
      	* src/virsh.c: Added 'virsh migrate' command.
      	* docs/libvir.html, docs/hvsupport.html: Updated hvsupport
      	  documentation.
      81005437
  26. 16 8月, 2007 1 次提交