diff options
Diffstat (limited to 'main')
-rw-r--r-- | main/cli.c | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/main/cli.c b/main/cli.c index d1d4bb3a2..d8814f05c 100644 --- a/main/cli.c +++ b/main/cli.c @@ -235,7 +235,9 @@ static char *complete_fn(const char *word, int state) c += (strlen(ast_config_AST_MODULE_DIR) + 1); if (c) c = ast_strdup(c); - free(d); + if (d) { + free(d); + } return c; } |