Re: [PATCH 3/3] python: avoid unlikely sign extension bug

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On 08/02/2011 12:12 PM, Eric Blake wrote:
Detected by Coverity; same analysis as for commit f73198df.

* python/libvirt-override.c (libvirt_virDomainGetVcpuPinInfo): Use
correct type.
---
  python/libvirt-override.c |    2 +-
  1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/python/libvirt-override.c b/python/libvirt-override.c
index aa84438..b5650e2 100644
--- a/python/libvirt-override.c
+++ b/python/libvirt-override.c
@@ -1114,7 +1114,7 @@ libvirt_virDomainGetVcpuPinInfo(PyObject *self ATTRIBUTE_UNUSED,
      virNodeInfo nodeinfo;
      virDomainInfo dominfo;
      unsigned char *cpumaps;
-    int cpumaplen, vcpu, pcpu;
+    size_t cpumaplen, vcpu, pcpu;
      unsigned int flags;
      int i_retval;

ACK.

--
libvir-list mailing list
libvir-list@xxxxxxxxxx
https://www.redhat.com/mailman/listinfo/libvir-list


[Index of Archives]     [Virt Tools]     [Libvirt Users]     [Lib OS Info]     [Fedora Users]     [Fedora Desktop]     [Fedora SELinux]     [Big List of Linux Books]     [Yosemite News]     [KDE Users]     [Fedora Tools]