aboutsummaryrefslogtreecommitdiff
path: root/include
diff options
context:
space:
mode:
authorRon Yorston <rmy@pobox.com>2024-01-04 07:58:00 +0000
committerRon Yorston <rmy@pobox.com>2024-01-04 07:58:00 +0000
commit9197a9ef026e3d57d291f05ea6f91956d152d116 (patch)
tree57eaef12ecb831422c66d95ba0c2022bbfd7f50d /include
parent306601c86fa1cc6c210b7f18d597b8c0821ab19a (diff)
downloadbusybox-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.h1
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;
589const char *bb_basename(const char *name) FAST_FUNC; 589const 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) */
591char *last_char_is(const char *s, int c) FAST_FUNC; 591char *last_char_is(const char *s, int c) FAST_FUNC;
592char *last_char_is_dir_sep(const char *s) FAST_FUNC;
592const char* endofname(const char *name) FAST_FUNC; 593const char* endofname(const char *name) FAST_FUNC;
593char *is_prefixed_with(const char *string, const char *key) FAST_FUNC; 594char *is_prefixed_with(const char *string, const char *key) FAST_FUNC;
594char *is_suffixed_with(const char *string, const char *key) FAST_FUNC; 595char *is_suffixed_with(const char *string, const char *key) FAST_FUNC;