From d4fff6b569c037923e0c4b77537f29a1a1b3e10b Mon Sep 17 00:00:00 2001 From: Gulevich Vasili Date: Wed, 14 Mar 2012 14:03:41 +0700 Subject: [PATCH] Macro argument bug fixed. --- lsi6camac.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/lsi6camac.h b/lsi6camac.h index cee1710..1555f51 100644 --- a/lsi6camac.h +++ b/lsi6camac.h @@ -33,8 +33,8 @@ #include #endif -#define NAF(n,a,f) (((f&0x1f)<<16) | ((n&0x1f)<<4) | (a&0xf)) -#define NAF24(n,a,f) (((f&0x1f)<<16) | ((n&0x1f)<<4) | (a&0xf) | CAMAC_24) +#define NAF(n,a,f) ((((f)&0x1f)<<16) | (((n)&0x1f)<<4) | ((a)&0xf)) +#define NAF24(n,a,f) ((((f)&0x1f)<<16) | (((n)&0x1f)<<4) | ((a)&0xf) | CAMAC_24) #define N_NAF(naf) (((naf) >> 4 ) & 0x1f) #define A_NAF(naf) ((naf) & 0xf)