diff options
Diffstat (limited to 'src/src/functions.h')
-rw-r--r-- | src/src/functions.h | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/src/src/functions.h b/src/src/functions.h index f3877563d..28d6f26a6 100644 --- a/src/src/functions.h +++ b/src/src/functions.h @@ -13,6 +13,7 @@ are in in fact in separate headers. */ #ifndef _FUNCTIONS_H_ #define _FUNCTIONS_H_ +#include <ctype.h> #include <sys/time.h> @@ -666,6 +667,15 @@ return US strncpy(CS dst, CCS src, n); /*XXX will likely need unchecked copy also */ +/* Advance the string pointer given over any whitespace. +Return the next char as there's enought places using it to be useful. */ + +#define Uskip_whitespace(sp) skip_whitespace(CUSS sp) + +static inline uschar skip_whitespace(const uschar ** sp) +{ while (isspace(**sp)) (*sp)++; return **sp; } + + /******************************************************************************/ #if !defined(MACRO_PREDEF) && !defined(COMPILE_UTILITY) |