--- libaitio/inc/aitio.h 2012/04/10 15:33:41 1.16.2.11 +++ libaitio/inc/aitio.h 2012/04/11 15:01:03 1.16.2.12 @@ -3,7 +3,7 @@ * by Michael Pounov * * $Author: misho $ -* $Id: aitio.h,v 1.16.2.11 2012/04/10 15:33:41 misho Exp $ +* $Id: aitio.h,v 1.16.2.12 2012/04/11 15:01:03 misho Exp $ * ************************************************************************** The ELWIX and AITNET software is distributed under the following @@ -119,11 +119,11 @@ typedef struct { #define AIT_LEN(_vl) (_vl)->val_len #define AIT_KEY(_vl) (_vl)->val_key #define AIT_RAW(_vl) (_vl)->val.net -#define AIT_VOID(_vl) (_vl)->val.ptr +#define AIT_ADDR(_vl) (_vl)->val.ptr #define AIT_BLOB_CHUNKS(_vl, _n) (AIT_LEN((_vl)) / _n + (AIT_LEN((_vl)) % _n) ? 1 : 0) #define AIT_ISEMPTY(_vl) (AIT_TYPE((_vl)) == empty) -#define AIT_GET_LIKE(_vl, _type) ((_type) (_vl)->val.ptr) +#define AIT_GET_LIKE(_vl, _type) ((_type) AIT_ADDR(_vl)) #define AIT_GET_PTR(_vl) (assert(AIT_TYPE((_vl)) == ptr), (_vl)->val.ptr) #define AIT_GET_DATA(_vl) (assert(AIT_TYPE((_vl)) == data), (_vl)->val_data)