summaryrefslogtreecommitdiff
path: root/source4/include/smb_macros.h
diff options
context:
space:
mode:
authorAndrew Tridgell <tridge@samba.org>2004-11-03 00:38:05 +0000
committerGerald (Jerry) Carter <jerry@samba.org>2007-10-10 13:05:22 -0500
commit02785df1b06647f1adaaac3c93f363ec5070a941 (patch)
tree70b42e956555d7f513c13fb80cb6ab799fb13d7c /source4/include/smb_macros.h
parent6f214cc510a59b7a65ee9d4486baf14a3e579f73 (diff)
downloadsamba-02785df1b06647f1adaaac3c93f363ec5070a941.tar.gz
samba-02785df1b06647f1adaaac3c93f363ec5070a941.tar.bz2
samba-02785df1b06647f1adaaac3c93f363ec5070a941.zip
r3497: removed some include cruft, and split out librpc/gen_ndr/tables.h
(This used to be commit 7dd3a5a6dadb0edc4fad56deba84f24b1e6dd2bc)
Diffstat (limited to 'source4/include/smb_macros.h')
-rw-r--r--source4/include/smb_macros.h54
1 files changed, 12 insertions, 42 deletions
diff --git a/source4/include/smb_macros.h b/source4/include/smb_macros.h
index 02c8fc3af4..0f13341821 100644
--- a/source4/include/smb_macros.h
+++ b/source4/include/smb_macros.h
@@ -86,25 +86,6 @@
#define VALID_SNUM(snum) (lp_snum_ok(snum))
#define GUEST_OK(snum) (VALID_SNUM(snum) && lp_guest_ok(snum))
-/*
- * Used by the stat cache code to check if a returned
- * stat structure is valid.
- */
-
-#define VALID_STAT(st) ((st).st_nlink != 0)
-#define VALID_STAT_OF_DIR(st) (VALID_STAT(st) && S_ISDIR((st).st_mode))
-
-#ifndef MIN
-#define MIN(a,b) ((a)<(b)?(a):(b))
-#endif
-#ifndef MAX
-#define MAX(a,b) ((a)>(b)?(a):(b))
-#endif
-
-#ifndef ABS
-#define ABS(a) ((a)>0?(a):(-(a)))
-#endif
-
/* these are the datagram types */
#define DGRAM_DIRECT_UNIQUE 0x10
@@ -132,35 +113,24 @@ true if two IP addresses are equal
#define ip_equal(ip1,ip2) ((ip1).s_addr == (ip2).s_addr)
#define ipv4_equal(ip1,ip2) ((ip1).addr == (ip2).addr)
-/*****************************************************************
- splits out the last subkey of a key
- *****************************************************************/
-
-#define reg_get_subkey(full_keyname, key_name, subkey_name) \
- split_at_last_component(full_keyname, key_name, '\\', subkey_name)
-
-/****************************************************************************
- Used by dptr_zero.
-****************************************************************************/
-
-#define DPTR_MASK ((uint32_t)(((uint32_t)1)<<31))
-
-/****************************************************************************
- Return True if the offset is at zero.
-****************************************************************************/
-
-#define dptr_zero(buf) ((IVAL(buf,1)&~DPTR_MASK) == 0)
-
/*******************************************************************
copy an IP address from one buffer to another
********************************************************************/
#define putip(dest,src) memcpy(dest,src,4)
-/*******************************************************************
- Return True if a server has CIFS UNIX capabilities.
-********************************************************************/
-#define SERVER_HAS_UNIX_CIFS(c) (cli_state_has_unix_cifs(c))
+#ifndef MIN
+#define MIN(a,b) ((a)<(b)?(a):(b))
+#endif
+
+#ifndef MAX
+#define MAX(a,b) ((a)>(b)?(a):(b))
+#endif
+
+#ifndef ABS
+#define ABS(a) ((a)>0?(a):(-(a)))
+#endif
+
#endif /* _SMB_MACROS_H */