diff options
author | Lennart Poettering <lennart@poettering.net> | 2014-08-21 16:22:34 +0200 |
---|---|---|
committer | Lennart Poettering <lennart@poettering.net> | 2014-08-21 17:24:21 +0200 |
commit | 28849dbadb7cd127f7f89e8892ec94c6a05070da (patch) | |
tree | f147f6937402f82c88b6a207a5c6492ff5d89be4 /src/shared/strv.h | |
parent | f49650cee2c5256dc0491432e1f12a4ae19be6c5 (diff) |
service,strv: introduce strv_find_startswith() and make use of it
Unlike strv_find_prefix() the new call will return a pointer to the
suffix of the item we found, instead of the whole item. This is more
closer inline with what startswith() does, and allows us to simplify a
couple of invocations.
Diffstat (limited to 'src/shared/strv.h')
-rw-r--r-- | src/shared/strv.h | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/src/shared/strv.h b/src/shared/strv.h index ee55c148aa..9c9633c515 100644 --- a/src/shared/strv.h +++ b/src/shared/strv.h @@ -28,6 +28,7 @@ char *strv_find(char **l, const char *name) _pure_; char *strv_find_prefix(char **l, const char *name) _pure_; +char *strv_find_startswith(char **l, const char *name) _pure_; void strv_free(char **l); DEFINE_TRIVIAL_CLEANUP_FUNC(char**, strv_free); |