version 1.2, 1996/06/10 11:21:25 |
version 1.3, 1997/01/17 07:18:02 |
|
|
{ |
{ |
char *base; |
char *base; |
|
|
base = rindex (name, '/'); |
base = strrchr (name, '/'); |
return base ? base + 1 : name; |
return base ? base + 1 : name; |
} |
} |
|
|
|
|
char *slash; |
char *slash; |
int length; /* Length of result, not including NUL. */ |
int length; /* Length of result, not including NUL. */ |
|
|
slash = rindex (path, '/'); |
slash = strrchr (path, '/'); |
if (slash == 0) |
if (slash == 0) |
{ |
{ |
/* File is in the current directory. */ |
/* File is in the current directory. */ |