Re: [Qemu-devel] [PATCH] i440fx-test: guard ARRAY_SIZE definition with #ifndef

2015-04-30 Thread Michael Tokarev
30.04.2015 22:16, Emilio G. Cota wrote: > ARRAY_SIZE is defined in osdep.h so having an unconditional > definition here is fragile. Fragile in what sense? Nothing in that file includes osdep.h. At the maximum, compiler will issue a warning about redefinition (it should really be redefinition, not

Re: [Qemu-devel] [PATCH] i440fx-test: guard ARRAY_SIZE definition with #ifndef

2015-04-30 Thread Peter Maydell
On 30 April 2015 at 20:28, Stefan Weil wrote: > 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. FWIW, the original patch of this failed to build on x86 too, so I don't think we currently include osdep.

Re: [Qemu-devel] [PATCH] i440fx-test: guard ARRAY_SIZE definition with #ifndef

2015-04-30 Thread Stefan Weil
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 --- tests/i440fx-test.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/tests/i440fx-test.c b/tests/i440fx-test.c index d

[Qemu-devel] [PATCH] i440fx-test: guard ARRAY_SIZE definition with #ifndef

2015-04-30 Thread Emilio G. Cota
ARRAY_SIZE is defined in osdep.h so having an unconditional definition here is fragile. Signed-off-by: Emilio G. Cota --- 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 ++