From f55aa55a81195ab36c92e3e80fd344adf6b5d6c9 Mon Sep 17 00:00:00 2001 From: "Richard M. Stallman" Date: Sun, 9 Jun 1996 19:12:26 +0000 Subject: [PATCH] (main): Copy cwd when appending slash. --- lib-src/etags.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/lib-src/etags.c b/lib-src/etags.c index 3445d2de8a0..34948781689 100644 --- a/lib-src/etags.c +++ b/lib-src/etags.c @@ -856,8 +856,8 @@ main (argc, argv) if (tagfile == NULL) tagfile = CTAGS ? "tags" : "TAGS"; cwd = etags_getcwd (); /* the current working directory */ - if (cwd[strlen(cwd)-1] != '/') - strcat (cwd, "/"); + if (cwd[strlen (cwd) - 1] != '/') + cwd = concat (cwd, "/", ""); if (streq (tagfile, "-")) tagfiledir = cwd; else -- 2.39.2