Eric Blake eb9093763f maint: forbid 'int foo = true'
I noticed this while working on qemuDomainGetBlockInfo.  Assigning
a bool value to an int variable compiles fine, but raises red flags
on the maintenance front as it becomes too easy to assign -1 or 2
or any other non-bool value to the same variable.

* cfg.mk (sc_prohibit_int_assign_bool): New rule.
* src/conf/snapshot_conf.c (virDomainSnapshotRedefinePrep): Fix
offenders.
* src/qemu/qemu_driver.c (qemuDomainGetBlockInfo)
(qemuDomainSnapshotCreateXML): Likewise.
* src/test/test_driver.c (testDomainSnapshotAlignDisks):
Likewise.
* src/util/vircgroup.c (virCgroupSupportsCpuBW): Likewise.
* src/util/virpci.c (virPCIDeviceBindToStub): Likewise.
* src/util/virutil.c (virIsCapableVport): Likewise.
* tools/virsh-domain-monitor.c (cmdDomMemStat): Likewise.
* tools/virsh-domain.c (cmdBlockResize, cmdScreenshot)
(cmdInjectNMI, cmdSendKey, cmdSendProcessSignal)
(cmdDetachInterface): Likewise.

Signed-off-by: Eric Blake <eblake@redhat.com>
2014-11-19 08:20:39 -07:00
..
2014-07-16 06:48:53 -06:00
2014-08-23 14:29:24 -06:00
2014-11-19 08:20:39 -07:00
2014-05-06 11:22:13 -04:00
2014-07-29 11:25:16 +01:00
2014-04-07 06:14:45 -06:00
2014-04-07 06:14:45 -06:00
2014-10-22 13:09:49 +01:00
2013-12-24 17:36:47 +01:00
2013-12-24 17:36:47 +01:00
2014-04-07 06:14:45 -06:00
2014-04-07 06:14:45 -06:00
2014-11-19 08:20:39 -07:00
2014-07-28 14:10:29 -06:00
2014-03-04 12:24:13 +00:00
2014-10-22 12:54:38 +04:00
2014-10-15 09:25:33 +02:00
2014-07-03 10:41:15 +02:00
2014-03-04 12:24:13 +00:00
2014-11-19 08:20:39 -07:00