mirror of
https://github.com/sudo-project/sudo.git
synced 2025-08-31 06:15:37 +00:00
Add a GNU-compatible version of basename(3).
Unlike POSIX basename(3), the GNU variant does not modify its argument. Note that basename of a path ending in "/" returns an empty string.
This commit is contained in:
@@ -188,6 +188,10 @@ sudo_dso_public int aix_setauthdb_v1(char *user);
|
||||
sudo_dso_public int aix_setauthdb_v2(char *user, char *registry);
|
||||
#define aix_setauthdb(_a, _b) aix_setauthdb_v2((_a), (_b))
|
||||
|
||||
/* basename.c */
|
||||
sudo_dso_public char *sudo_basename_v1(const char *filename);
|
||||
#define sudo_basename(_a) sudo_basename_v1(_a)
|
||||
|
||||
/* gethostname.c */
|
||||
sudo_dso_public char *sudo_gethostname_v1(void);
|
||||
#define sudo_gethostname() sudo_gethostname_v1()
|
||||
|
Reference in New Issue
Block a user