Am 30.04.2015 um 21:16 schrieb Emilio G. Cota:
ARRAY_SIZE is defined in osdep.h so having an unconditional
definition here is fragile.

Signed-off-by: Emilio G. Cota <c...@braap.org>
---
  tests/i440fx-test.c | 2 ++
  1 file changed, 2 insertions(+)

diff --git a/tests/i440fx-test.c b/tests/i440fx-test.c
index d0bc8de..d610e66 100644
--- a/tests/i440fx-test.c
+++ b/tests/i440fx-test.c
@@ -27,7 +27,9 @@
#define BROKEN 1 +#ifndef ARRAY_SIZE
  #define ARRAY_SIZE(array) (sizeof(array) / sizeof((array)[0]))
+#endif
typedef struct TestData
  {

Why not include osdep.h via qemu-common.h and remove all other include statements which then are no longer needed? I'd prefer that variant.

Cheers
Stefan


Reply via email to