commit 148806b33200a8127738de3233b202f78fdfb93d parent e6be1c3e7d61405643f05601806ef15ca2fdc91d Author: falkTX <falktx@falktx.com> Date: Wed, 17 Aug 2022 10:25:04 +0100 Protect ARRAY_SIZE macro from multiple division usage Diffstat:
M | distrho/src/DistrhoDefines.h | | | 2 | +- |
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/distrho/src/DistrhoDefines.h b/distrho/src/DistrhoDefines.h @@ -211,7 +211,7 @@ private: \ #endif /* Useful macros */ -#define ARRAY_SIZE(ARRAY) sizeof(ARRAY)/sizeof(ARRAY[0]) +#define ARRAY_SIZE(ARRAY) (sizeof(ARRAY)/sizeof(ARRAY[0])) /* Useful typedefs */ typedef unsigned char uchar;