summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorThomas Roessler <roessler@does-not-exist.org>2001-05-24 09:57:32 +0000
committerThomas Roessler <roessler@does-not-exist.org>2001-05-24 09:57:32 +0000
commit1a3c952de8e3c20da7607be381c2450767c46f9c (patch)
tree770c7b12a3a30fa1fb8c7f11b935a5297fd47d20
parent727a3866cff90ad1fcdd11a5da1be9dfd7a5ce57 (diff)
patch-bac.chdir-20010523.2
-rw-r--r--browser.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/browser.c b/browser.c
index 50a8b25c..7d259dd7 100644
--- a/browser.c
+++ b/browser.c
@@ -909,7 +909,7 @@ void _mutt_select_file (char *f, size_t flen, int flags, char ***files, int *num
{
/* add '/' at the end of the directory name if not already there */
int len=mutt_strlen(LastDir);
- if (LastDir[len-1] != '/' && sizeof (buf) > len)
+ if (len && LastDir[len-1] != '/' && sizeof (buf) > len)
buf[len]='/';
}