
On 05/20/2010 02:45 PM, Jim Fehlig wrote:
for (i = QEMU_VNC_PORT_MIN; i < QEMU_VNC_PORT_MAX; i++) { int fd; int reuse = 1; struct sockaddr_in addr; + bool used = false; + + virBitmapGetBit(driver->reservedVNCPorts, i - QEMU_VNC_PORT_MIN, &used);
For now, we're safe not checking for failure here. But maybe we should add an error check and a VIR_DEBUG to be proactive in case the size of driver->reservedVNCPorts is ever accidentally changed? (Hmm, maybe an addendum to my comments on 1/3, that the bitmap.h file should mark functions as ATTRIBUTE_RETURN_CHECK?) I could go either way, so for now, I'll wait for other comments (and for the fixes to bitmap.h) before giving an ack. -- Eric Blake eblake@redhat.com +1-801-349-2682 Libvirt virtualization library http://libvirt.org