fix command listing for top level CLI commands (issue #5416)
authorRussell Bryant <russell@russellbryant.com>
Tue, 11 Oct 2005 20:20:40 +0000 (20:20 +0000)
committerRussell Bryant <russell@russellbryant.com>
Tue, 11 Oct 2005 20:20:40 +0000 (20:20 +0000)
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@6740 65c4cc65-6c06-0410-ace0-fbb531ad65f3

cli.c

diff --git a/cli.c b/cli.c
index 7ec76ba..b32ca13 100755 (executable)
--- a/cli.c
+++ b/cli.c
@@ -949,7 +949,7 @@ static void join(char *dest, size_t destsize, char *w[], int tws)
                        strncat(dest, " ", destsize - strlen(dest) - 1);
                strncat(dest, w[x], destsize - strlen(dest) - 1);
        }
-       if (tws)
+       if (tws && !ast_strlen_zero(dest))
                strncat(dest, " ", destsize - strlen(dest) - 1);
 }