diff options
author | Rob Clark <robdclark@gmail.com> | 2019-01-06 09:47:02 -0500 |
---|---|---|
committer | Rob Clark <robdclark@gmail.com> | 2019-01-10 10:52:51 -0500 |
commit | d8da3dcfdfe33ee525cf562e928a5266ac69843c (patch) | |
tree | 1dc1e9de501eb85824e74c6c41943cf9a472cb0b | |
parent | 485b385e966a63cecc143765d112d267b299ffe5 (diff) | |
download | kmscube-d8da3dcfdfe33ee525cf562e928a5266ac69843c.tar.gz |
De-duplicate ARRAY_SIZE macro
-rw-r--r-- | common.h | 2 | ||||
-rw-r--r-- | cube-tex.c | 2 | ||||
-rw-r--r-- | kmscube.c | 2 |
3 files changed, 2 insertions, 4 deletions
@@ -33,6 +33,8 @@ #include <drm_fourcc.h> #include <stdbool.h> +#define ARRAY_SIZE(arr) (sizeof(arr) / sizeof((arr)[0])) + #ifndef DRM_FORMAT_MOD_LINEAR #define DRM_FORMAT_MOD_LINEAR 0 #endif @@ -30,8 +30,6 @@ #include "common.h" #include "esUtil.h" -#define ARRAY_SIZE(x) (sizeof(x) / sizeof((x)[0])) - struct { struct egl egl; @@ -37,8 +37,6 @@ GST_DEBUG_CATEGORY(kmscube_debug); #endif -#define ARRAY_SIZE(arr) (sizeof(arr) / sizeof((arr)[0])) - static const struct egl *egl; static const struct gbm *gbm; static const struct drm *drm; |