summaryrefslogtreecommitdiff
path: root/source3
diff options
context:
space:
mode:
authorAndrew Tridgell <tridge@samba.org>1998-08-21 09:43:21 +0000
committerAndrew Tridgell <tridge@samba.org>1998-08-21 09:43:21 +0000
commit7d657984bbdf867319e96dee6fbf5ed5b835ad14 (patch)
treebd80542fdb93873ab92a5e184bbfbf39367a396d /source3
parent04c4ca1b241f3ef49e4a626c35141fea3cb1099a (diff)
downloadsamba-7d657984bbdf867319e96dee6fbf5ed5b835ad14.tar.gz
samba-7d657984bbdf867319e96dee6fbf5ed5b835ad14.tar.bz2
samba-7d657984bbdf867319e96dee6fbf5ed5b835ad14.zip
added a macro ZERO_STRUCT() which is useful for initialising
structures declared on the stack. (This used to be commit f323af8fce54cd5d51c848aa7ea7be4dd3538f2e)
Diffstat (limited to 'source3')
-rw-r--r--source3/include/smb.h3
1 files changed, 3 insertions, 0 deletions
diff --git a/source3/include/smb.h b/source3/include/smb.h
index e88737f046..9d6c8d7e29 100644
--- a/source3/include/smb.h
+++ b/source3/include/smb.h
@@ -1563,6 +1563,9 @@ extern int unix_ERR_code;
#define CMD_REPLY 0x8000
+/* useful macros */
+#define ZERO_STRUCT(x) memset((char *)&(x), 0, sizeof(x))
+
#endif /* _SMB_H */
#include "ntdomain.h"