Daniel P. Berrange 68b19542ec Use explicit boolean comparison in OOM check
GCC 7 gets upset by

   if (!tmp && (size * count))

warning

  util/viralloc.c: In function 'virReallocN':
  util/viralloc.c:246:23: error: '*' in boolean context, suggest '&&' instead [-Werror=int-in-bool-context]
     if (!tmp && (size * count)) {
                 ~~~~~~^~~~~~~~

Keep it happy by adding != 0 to the right hand expression
so it realizes we really are wanting to treat the result
of the arithmetic expression as a boolean

Signed-off-by: Daniel P. Berrange <berrange@redhat.com>
(cherry picked from commit 09db97d3cbf334ea28969f08bac8a2fe4aafda16)
2017-08-04 15:58:05 -04:00
..
2016-06-16 06:17:58 -04:00
2016-06-20 12:09:52 +02:00
2017-08-03 17:19:37 -04:00
2017-08-04 15:57:15 -04:00
2017-05-30 18:27:30 -04:00
2016-02-11 11:35:02 +01:00
2016-02-11 11:35:02 +01:00
2015-07-10 11:47:13 +02:00
2016-06-16 13:09:19 -04:00
2016-06-24 14:20:57 +02:00
2016-06-24 14:20:57 +02:00
2016-02-11 11:35:02 +01:00
2016-04-20 12:46:48 +02:00
2017-08-04 15:57:15 -04:00
2016-08-02 14:20:31 +02:00
2016-08-02 14:20:31 +02:00
2014-10-22 13:09:49 +01:00
2016-03-18 09:43:45 +01:00
2016-07-28 08:27:13 -04:00
2016-07-28 08:27:13 -04:00
2015-04-02 16:05:32 +02:00
2017-08-04 15:57:15 -04:00
2015-04-15 16:43:28 +02:00
2016-06-24 14:20:57 +02:00
2014-12-16 11:15:27 +01:00
2016-06-24 14:20:57 +02:00
2016-06-03 10:52:16 +02:00
2015-03-13 15:31:33 +01:00
2016-06-24 14:20:57 +02:00
2016-04-06 20:27:09 -04:00
2016-06-24 14:20:57 +02:00
2016-08-08 08:15:59 +02:00
2016-02-05 16:11:50 +01:00
2015-03-25 10:00:53 +01:00
2016-05-28 13:49:14 +02:00
2016-06-24 14:20:57 +02:00
2017-08-04 15:57:15 -04:00