diff options
author | Ron Yorston <rmy@pobox.com> | 2024-01-04 07:58:00 +0000 |
---|---|---|
committer | Ron Yorston <rmy@pobox.com> | 2024-01-04 07:58:00 +0000 |
commit | 9197a9ef026e3d57d291f05ea6f91956d152d116 (patch) | |
tree | 57eaef12ecb831422c66d95ba0c2022bbfd7f50d /include | |
parent | 306601c86fa1cc6c210b7f18d597b8c0821ab19a (diff) | |
download | busybox-w32-9197a9ef026e3d57d291f05ea6f91956d152d116.tar.gz busybox-w32-9197a9ef026e3d57d291f05ea6f91956d152d116.tar.bz2 busybox-w32-9197a9ef026e3d57d291f05ea6f91956d152d116.zip |
libbb: introduce last_char_is_dir_sep()
Add a convenience function to determine if the last character of
a string is a directory separator.
Adds 16-32 bytes.
Diffstat (limited to 'include')
-rw-r--r-- | include/libbb.h | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/include/libbb.h b/include/libbb.h index a469bfe03..6549c8c83 100644 --- a/include/libbb.h +++ b/include/libbb.h | |||
@@ -589,6 +589,7 @@ char *bb_get_last_path_component_nostrip(const char *path) FAST_FUNC; | |||
589 | const char *bb_basename(const char *name) FAST_FUNC; | 589 | const char *bb_basename(const char *name) FAST_FUNC; |
590 | /* NB: can violate const-ness (similarly to strchr) */ | 590 | /* NB: can violate const-ness (similarly to strchr) */ |
591 | char *last_char_is(const char *s, int c) FAST_FUNC; | 591 | char *last_char_is(const char *s, int c) FAST_FUNC; |
592 | char *last_char_is_dir_sep(const char *s) FAST_FUNC; | ||
592 | const char* endofname(const char *name) FAST_FUNC; | 593 | const char* endofname(const char *name) FAST_FUNC; |
593 | char *is_prefixed_with(const char *string, const char *key) FAST_FUNC; | 594 | char *is_prefixed_with(const char *string, const char *key) FAST_FUNC; |
594 | char *is_suffixed_with(const char *string, const char *key) FAST_FUNC; | 595 | char *is_suffixed_with(const char *string, const char *key) FAST_FUNC; |