diff options
Diffstat (limited to 'libbb/bb_basename.c')
-rw-r--r-- | libbb/bb_basename.c | 23 |
1 files changed, 0 insertions, 23 deletions
diff --git a/libbb/bb_basename.c b/libbb/bb_basename.c deleted file mode 100644 index 92fdb6545..000000000 --- a/libbb/bb_basename.c +++ /dev/null | |||
@@ -1,23 +0,0 @@ | |||
1 | /* vi: set sw=4 ts=4: */ | ||
2 | /* | ||
3 | * Utility routines. | ||
4 | * | ||
5 | * Copyright (C) 2007 Denys Vlasenko | ||
6 | * | ||
7 | * Licensed under GPLv2, see file LICENSE in this source tree. | ||
8 | */ | ||
9 | |||
10 | #include "libbb.h" | ||
11 | |||
12 | const char* FAST_FUNC bb_basename(const char *name) | ||
13 | { | ||
14 | const char *cp = strrchr(name, '/'); | ||
15 | if (cp) | ||
16 | return cp + 1; | ||
17 | if (ENABLE_PLATFORM_MINGW32) { | ||
18 | cp = strrchr(name, '\\'); | ||
19 | if (cp) | ||
20 | return cp + 1; | ||
21 | } | ||
22 | return name; | ||
23 | } | ||