mirror of
https://github.com/samba-team/samba.git
synced 2025-11-16 20:23:50 +03:00
r18439: 2nd try at a talloc_move() api. This type with the ** ptr interface
exposed. Unfortunately this generates a large number of type punning warnings. We'll have to find some magic to hide those.
This commit is contained in:
committed by
Gerald (Jerry) Carter
parent
b0de283882
commit
254cbf09de
@@ -73,7 +73,7 @@ typedef void TALLOC_CTX;
|
||||
#endif
|
||||
|
||||
#define talloc_reference(ctx, ptr) (_TALLOC_TYPEOF(ptr))_talloc_reference((ctx),(ptr))
|
||||
#define talloc_move(ctx, ptr) (_TALLOC_TYPEOF(ptr))_talloc_move((ctx),&(ptr))
|
||||
#define talloc_move(ctx, ptr) (_TALLOC_TYPEOF(*(ptr)))_talloc_move((ctx),(const void **)(ptr))
|
||||
|
||||
/* useful macros for creating type checked pointers */
|
||||
#define talloc(ctx, type) (type *)talloc_named_const(ctx, sizeof(type), #type)
|
||||
|
||||
Reference in New Issue
Block a user