diff options
author | Karolin Seeger <kseeger@samba.org> | 2008-06-27 15:51:35 +0200 |
---|---|---|
committer | Karolin Seeger <kseeger@samba.org> | 2008-06-27 15:51:35 +0200 |
commit | e08943f8d855b85765615b2a231fb65d5788a2a6 (patch) | |
tree | d84fa5b1dfa0055d74da248b25d47f5164b1d42f /source3/include | |
parent | 006515d88923202c4a129cfa477eaefc01f1fc78 (diff) | |
download | samba-e08943f8d855b85765615b2a231fb65d5788a2a6.tar.gz samba-e08943f8d855b85765615b2a231fb65d5788a2a6.tar.bz2 samba-e08943f8d855b85765615b2a231fb65d5788a2a6.zip |
Fix warnings on SuSE 9.0.
The macros "[un]likely" are already defined on SuSE 9.0.
Patch from Volker.
(This used to be commit 30d181c92463aecd6e649330d3645d86d5a17e43)
Diffstat (limited to 'source3/include')
-rw-r--r-- | source3/include/debug.h | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/source3/include/debug.h b/source3/include/debug.h index d8dafcbd45..d1716320b3 100644 --- a/source3/include/debug.h +++ b/source3/include/debug.h @@ -169,12 +169,20 @@ extern bool *DEBUGLEVEL_CLASS_ISSET; #if (__GNUC__ >= 3) /* the strange !! is to ensure that __builtin_expect() takes either 0 or 1 as its first argument */ +#ifndef likely #define likely(x) __builtin_expect(!!(x), 1) +#endif +#ifndef unlikely #define unlikely(x) __builtin_expect(!!(x), 0) +#endif #else +#ifndef likely #define likely(x) (x) +#endif +#ifndef unlikely #define unlikely(x) (x) #endif +#endif #define CHECK_DEBUGLVL( level ) \ ( ((level) <= MAX_DEBUG_LEVEL) && \ |