rc

[fork] interactive rc shell
Log | Files | Refs | README | LICENSE

commit 5df77bab6d3324c2b9dc696e38ccac9317b1ff70
parent f034ca39df7f6f513d0d4d4f479194592ac48645
Author: tgoodwin <tgoodwin>
Date:   Wed, 28 Oct 1998 14:19:43 +0000

  Portability: apparently some systems declare `char *basename(const
  char *)' in system header files.  Changing our basename() (in
  history.c) to match this prototype allows it to be compiled on such
  systems, and is harmless.  (Harmless, that is, if no system declares
  `char *basename(char *)'.)

Diffstat:
Mhistory.c | 2+-
1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/history.c b/history.c @@ -56,7 +56,7 @@ static char *newstr() { return ealloc((size_t)1024); } -static char *basename(char *s) { +static char *basename(const char *s) { char *t = strrchr(s, '/'); return (t == NULL) ? s : t + 1; }