diff options
Diffstat (limited to 'code/qcommon/q_shared.h')
-rw-r--r-- | code/qcommon/q_shared.h | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/code/qcommon/q_shared.h b/code/qcommon/q_shared.h index 45bd046..d6c69dc 100644 --- a/code/qcommon/q_shared.h +++ b/code/qcommon/q_shared.h @@ -111,7 +111,13 @@ typedef int sfxHandle_t; typedef int fileHandle_t; typedef int clipHandle_t; -#define ALIGN(x) ((x+sizeof(long)-1) & ~(sizeof(long)-1)) +#define PAD(x,y) (((x)+(y)-1) & ~((y)-1)) + +#ifdef __GNUC__ +#define ALIGN(x) __attribute__((aligned(x))) +#else +#define ALIGN(x) +#endif #ifndef NULL #define NULL ((void *)0) |