From 7dea9669bbdfe2b8cb239189e3b5e8b167e33b5a Mon Sep 17 00:00:00 2001 From: Clint Adams Date: Wed, 6 Feb 2002 16:48:28 +0000 Subject: 16577: don't return a single dot as the path head of a slash. --- Src/hist.c | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) (limited to 'Src/hist.c') diff --git a/Src/hist.c b/Src/hist.c index dfd34c716..e5fcf5ff8 100644 --- a/Src/hist.c +++ b/Src/hist.c @@ -1378,7 +1378,11 @@ remtpath(char **junkptr) while (str >= *junkptr && !IS_DIRSEP(*str)) --str; if (str < *junkptr) { - *junkptr = dupstring ("."); + if (IS_DIRSEP(**junkptr)) + *junkptr = dupstring ("/"); + else + *junkptr = dupstring ("."); + return 0; } /* repeated slashes are considered like a single slash */ -- cgit 1.4.1