From b8e6f042c57739cc2b183395a3f9dfd64a6eb3d2 Mon Sep 17 00:00:00 2001 From: David Bremner Date: Thu, 30 Aug 2018 08:29:13 -0300 Subject: [PATCH] util/string-util: export skip_space It's only few lines, but we already define the function, so make it usable elsewhere --- util/string-util.c | 2 +- util/string-util.h | 2 ++ 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/util/string-util.c b/util/string-util.c index b0108811..fc2058e0 100644 --- a/util/string-util.c +++ b/util/string-util.c @@ -141,7 +141,7 @@ make_boolean_term (void *ctx, const char *prefix, const char *term, return 0; } -static const char* +const char* skip_space (const char *str) { while (*str && isspace ((unsigned char) *str)) diff --git a/util/string-util.h b/util/string-util.h index 97770614..4c110a20 100644 --- a/util/string-util.h +++ b/util/string-util.h @@ -77,6 +77,8 @@ unsigned int strcase_hash (const void *ptr); void strip_trailing (char *str, char ch); +const char* skip_space (const char *str); + #ifdef __cplusplus } #endif