mirror of
https://github.com/coreutils/coreutils.git
synced 2024-11-26 11:23:47 +08:00
(basename): Make arg const.
This commit is contained in:
parent
99ce9e9832
commit
143415e6b8
@ -32,10 +32,10 @@
|
||||
|
||||
char *
|
||||
basename (name)
|
||||
char *name;
|
||||
const char *name;
|
||||
{
|
||||
char *base;
|
||||
|
||||
base = strrchr (name, '/');
|
||||
return base ? base + 1 : name;
|
||||
return base ? base + 1 : (char *) name;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user