Hide Forgot
Description of problem: When compiling libvirt-0.9.2-1.el6.src.rpm on x86_64 machine, it produced the following error informations ... CC libvirt_driver_qemu_la-qemu_monitor_json.lo CC libvirt_driver_qemu_la-qemu_driver.lo qemu/qemu_monitor_json.c: In function 'qemuMonitorJSONAddDrive': qemu/qemu_monitor_json.c:2468: warning: 'ret' may be used uninitialized in this function [-Wuninitialized] CC libvirt_driver_qemu_la-qemu_bridge_filter.lo CC libvirt_driver_lxc_la-lxc_conf.lo ... Version-Release number of selected component (if applicable): libvirt-0.9.2-1.el6.src.rpm How reproducible: always Steps to Reproduce: 1.install the libvirt-0.9.2-1.el6.src.rpm 2. cd /root/rpmbuild/SPECS 3. rpmbuild -bb libvirt.spec Actual results: it showed warning info. Expected results: no warning info. Additional info:
Created attachment 505917 [details] proposed patch I tried to initialize the ret variable to -1, it works.
Confirmed; the bug is RHEL-specific, due to a flaw in the libvirt-Support-virtio-disk-hotplug-in-JSON-mode.patch
I've incorporated Gunannan's patch into this respin: http://post-office.corp.redhat.com/archives/rhvirt-patches/2011-June/msg00349.html
I missed this when doing the rebase for libvirt-0.9.2-1.el6, it will be in the next build, Daniel
This bug has been verified on libvirt-0.9.3-1.el6.
Since the problem described in this bug report should be resolved in a recent advisory, it has been closed with a resolution of ERRATA. For information on the advisory, and where to find the updated files, follow the link below. If the solution does not work for you, open a new bug report. http://rhn.redhat.com/errata/RHBA-2011-1513.html