[PATCH 1/1] Samba4 poor mans debug_ctx()

Amin Azez azez at ufomechanic.net
Fri Feb 1 16:19:36 GMT 2008


DEBUG(), DEBUGADD() and friends can now use debug_ctx() in the
formatting expressions again,
e.g.

DEBUG(5,("Guid failed to match: %s\n", GUID_string(debug_ctx(), r->guid)));

Sadly it's done with macros (again) but when we need to save the 8 or 16
bytes of object code per DEBUG() expression we can do it the Samba 3 way
with added thread-safety for Samba 4. That could save up to 200K,
allowing 12 bytes for each occurrance of DEBUG...

Signed-off-by: Amin Azez <azez at ufomechanic.net>
---
 source/lib/util/debug.h |    4 ++++
 1 files changed, 4 insertions(+), 0 deletions(-)
-------------- next part --------------
A non-text attachment was scrubbed...
Name: 35ad82a8d92e547e1f5d7437cf6fcfd6fc867702.diff
Type: text/x-patch
Size: 605 bytes
Desc: not available
Url : http://lists.samba.org/archive/samba-technical/attachments/20080201/db5aad8a/35ad82a8d92e547e1f5d7437cf6fcfd6fc867702.bin


More information about the samba-technical mailing list