summaryrefslogtreecommitdiffstats
path: root/include/strutils.h
diff options
context:
space:
mode:
authorSami Kerola2013-08-29 16:50:17 +0200
committerSami Kerola2013-08-29 19:14:08 +0200
commit199e939d88333162f440ea50b83415dac625c89c (patch)
tree33b50feb3b2a065311e3c1477971e728e1fffccc /include/strutils.h
parentlib/time-util: copy time parsing functions from systemd (diff)
downloadkernel-qcow2-util-linux-199e939d88333162f440ea50b83415dac625c89c.tar.gz
kernel-qcow2-util-linux-199e939d88333162f440ea50b83415dac625c89c.tar.xz
kernel-qcow2-util-linux-199e939d88333162f440ea50b83415dac625c89c.zip
lib/strutils: move *swith() functions to private library
Avoid code dublication in libmount and time-util. Proposed-by: Karel Zak <kzak@redhat.com> Reference: http://markmail.org/message/h7zexvqsieqngtmx Signed-off-by: Sami Kerola <kerolasa@iki.fi>
Diffstat (limited to 'include/strutils.h')
-rw-r--r--include/strutils.h4
1 files changed, 4 insertions, 0 deletions
diff --git a/include/strutils.h b/include/strutils.h
index 709fcadc5..8d8a6e46c 100644
--- a/include/strutils.h
+++ b/include/strutils.h
@@ -102,4 +102,8 @@ extern int parse_range(const char *str, int *lower, int *upper, int def);
extern int streq_except_trailing_slash(const char *s1, const char *s2);
+extern char *startswith(const char *s, const char *prefix);
+extern char *startswith_no_case(const char *s, const char *prefix);
+extern char *endswith(const char *s, const char *postfix);
+
#endif