diff options
author | Stefan Metzmacher <metze@samba.org> | 2006-08-28 15:36:12 +0000 |
---|---|---|
committer | Gerald (Jerry) Carter <jerry@samba.org> | 2007-10-10 14:16:51 -0500 |
commit | 82d4c5095dab0b5c1011fd9f5b865a7c07715a7a (patch) | |
tree | 9bbf4192b1af28a4d11de5470da38a88cec7204b /source4/lib/talloc | |
parent | 6f7dd6ca075f223abe8c7b19b5377321f38b092c (diff) | |
download | samba-82d4c5095dab0b5c1011fd9f5b865a7c07715a7a.tar.gz samba-82d4c5095dab0b5c1011fd9f5b865a7c07715a7a.tar.bz2 samba-82d4c5095dab0b5c1011fd9f5b865a7c07715a7a.zip |
r17885: use _TALLOC_TYPEPF() consitently
metze
(This used to be commit 155cd6b88283b85c53c7ec65efcf431da7b649ac)
Diffstat (limited to 'source4/lib/talloc')
-rw-r--r-- | source4/lib/talloc/talloc.h | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/source4/lib/talloc/talloc.h b/source4/lib/talloc/talloc.h index b873bdb8aa..fec2e8d8d7 100644 --- a/source4/lib/talloc/talloc.h +++ b/source4/lib/talloc/talloc.h @@ -58,13 +58,12 @@ typedef void TALLOC_CTX; #define _TALLOC_TYPEOF(ptr) __typeof__(ptr) #define talloc_set_destructor(ptr, function) \ do { \ - int (*_talloc_destructor_fn)(typeof(ptr)) = (function); \ + int (*_talloc_destructor_fn)(_TALLOC_TYPEOF(ptr)) = (function); \ _talloc_set_destructor((ptr), (void *)_talloc_destructor_fn); \ } while(0) -#define _TALLOC_CHECK_TYPE(type,val) /* this extremely strange macro is to avoid some braindamaged warning stupidity in gcc 4.1.x */ -#define talloc_steal(ctx, ptr) ({ __typeof__(ptr) __talloc_steal_ret = (__typeof__(ptr))_talloc_steal((ctx),(ptr)); __talloc_steal_ret; }) +#define talloc_steal(ctx, ptr) ({ _TALLOC_TYPEOF(ptr) __talloc_steal_ret = (_TALLOC_TYPEOF(ptr))_talloc_steal((ctx),(ptr)); __talloc_steal_ret; }) #else #define talloc_set_destructor(ptr, function) \ _talloc_set_destructor((ptr), (int (*)(void *))(function)) |