1. 06 11月, 2014 13 次提交
  2. 05 11月, 2014 2 次提交
    • P
      remote: Fix memory leak in remoteConnectGetAllDomainStats · bf1f8e28
      Peter Krempa 提交于
      The remote call actually doesn't free the arguments array so we leak
      memory in case a domain list is specified. As the remote domain list
      array consists only of stolen pointers from the actual domain objects
      it's sufficient just to free the array.
      
      Valgrind message:
      ==1081452== 64 bytes in 1 blocks are definitely lost in loss record 632 of 726
      ==1081452==    at 0x4C296D0: calloc (vg_replace_malloc.c:618)
      ==1081452==    by 0x4EA5CB4: virAllocN (viralloc.c:191)
      ==1081452==    by 0x505D21E: remoteConnectGetAllDomainStats (remote_driver.c:7785)
      ==1081452==    by 0x50081AA: virDomainListGetStats (libvirt-domain.c:11080)
      ==1081452==    by 0x155249: cmdDomstats (virsh-domain-monitor.c:2147)
      ==1081452==    by 0x12FB73: vshCommandRun (virsh.c:1935)
      ==1081452==    by 0x133FEB: main (virsh.c:3719)
      bf1f8e28
    • P
      Memory: Use consistent type for all memory elements. · d426431f
      Prerna Saxena 提交于
      Domain memory elements such as max_balloon and cur_balloon are
      implemented as 'unsigned long long', whereas the 'memory' element
      in NUMA cells is implemented as 'unsigned int'.
      
      Use the same data type (unsigned long long) for 'memory' element
      in NUMA cells.
      Signed-off-by: NPrerna Saxena <prerna@linux.vnet.ibm.com>
      d426431f
  3. 04 11月, 2014 7 次提交
  4. 03 11月, 2014 11 次提交
  5. 01 11月, 2014 6 次提交
    • P
      hotplug: fix char device detach · e7e05801
      Pavel Hrdina 提交于
      Hotplugging and hotunplugging char devices is only supported through
      '-device' and the check for device capability should be independently.
      
      Coverity also complains about 'tmpChr->info.alias' could be NULL and we
      are dereferencing it but it somehow only in this case don't recognize
      that the value is set by 'qemuAssignDeviceChrAlias' so it's clearly
      false positive. Add sa_assert to make coverity happy.
      Signed-off-by: NPavel Hrdina <phrdina@redhat.com>
      e7e05801
    • P
      vbox_storage: fix coverity issue with overwriting value · bddf8561
      Pavel Hrdina 提交于
      Coverity is complaining about overwriting value in 'rc' variable
      without using the old value because it somehow doesn't recognize that
      the value is used by MACRO. The 'rc' variable is there only for checking
      return code so it's save to remove it and make coverity happy.
      Signed-off-by: NPavel Hrdina <phrdina@redhat.com>
      bddf8561
    • J
      Relax duplicate SCSI host pool checking · 59389231
      Ján Tomko 提交于
      Since commit 3f99d64d no new scsi_host pools can be defined
      if one of the already defined scsi_host pools does not refer
      to an accessible scsi_host adapter.
      
      Relax the check by skipping over these inaccessible pools
      when checking for duplicates.
      59389231
    • J
      Match scsi_host pools by parent address first · 77911d30
      Ján Tomko 提交于
      If both source adapters are specified by a parent address,
      just comparing the address is faster and catches even addresses
      that do not refer to valid adapters.
      77911d30
    • P
      mingw: fix build failure · d91c8e64
      Pavel Hrdina 提交于
      This macro seems to be defined only on linux/unix and it fails during
      mingw build. Its value is '16' (taken from net/if.h) so define it if
      it's not defined.
      Signed-off-by: NPavel Hrdina <phrdina@redhat.com>
      d91c8e64
    • E
      domain: fix parsing of memory tunables on 32-bit machines · 9998a657
      Eric Blake 提交于
      Commit 6c9a8a49 (Oct 2014) exposed a long-standing issue on 32-bit
      machines: code related to virDomainSetMemoryParameters has always
      been documented as using a 64-bit limit, but it was implemented by
      calling virDomainParseMemory which enforced an 'unsigned long'
      limit.  Since VIR_DOMAIN_MEMORY_PARAM_UNLIMITED capped to a
      long is -1, but virDomainParseScaledValue no longer accepts
      negative values, an attempt to use 2^53-1 as a hard memory limit
      started failing the testsuite.  However, the problem with capping
      things artificially low has existed for much longer - ever since
      commits 4888f0fb and 2e22f23b (Mar 2012) switched internal tracking
      from 'unsigned long' to 'unsigned long long' (prior to that time,
      the cap was a side-effect of the choice of types).  We _have_ to
      cap the balloon memory values, (no thanks to baked in 'unsigned long'
      of API such as virDomainSetMaxMemory or virDomainGetInfo with no
      counterpart API that guarantees 64-bit access to those numbers)
      but memory parameters have never needed the artificial limit.
      
      At any rate, the solution is to make the parser function gain a
      parameter, and only do the reduced 32-bit cap for the values that
      are constrained due to API.
      
      * src/conf/domain_conf.h (_virDomainMemtune): Add comments.
      * src/conf/domain_conf.c (virDomainParseMemory): Add parameter.
      (virDomainDefParseXML): Adjust callers.
      Signed-off-by: NEric Blake <eblake@redhat.com>
      9998a657
  6. 31 10月, 2014 1 次提交