aboutsummaryrefslogtreecommitdiffstats
path: root/main/asterisk.c
diff options
context:
space:
mode:
authorrussell <russell@f38db490-d61c-443f-a65b-d21fe96a405b>2007-01-19 16:56:17 +0000
committerrussell <russell@f38db490-d61c-443f-a65b-d21fe96a405b>2007-01-19 16:56:17 +0000
commit397418eb0c2c20f83505c9af8d5bb8aa89cab8af (patch)
tree1d6c68dd9d9abc642586d81b40c7d0a24e54697b /main/asterisk.c
parent02535742190661edf4107857b406448c494212d6 (diff)
Merged revisions 51300 via svnmerge from
https://origsvn.digium.com/svn/asterisk/branches/1.2 ........ r51300 | russell | 2007-01-19 10:44:09 -0600 (Fri, 19 Jan 2007) | 4 lines Fix a memory leak on command line tab completion. The container for the matches was freed, but the individual matches themselves were not. (issue #8851, arkadia) ........ git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.4@51302 f38db490-d61c-443f-a65b-d21fe96a405b
Diffstat (limited to 'main/asterisk.c')
-rw-r--r--main/asterisk.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/main/asterisk.c b/main/asterisk.c
index 40befc1cd..e5e38d725 100644
--- a/main/asterisk.c
+++ b/main/asterisk.c
@@ -2037,6 +2037,8 @@ static char *cli_complete(EditLine *el, int ch)
retval = CC_REFRESH;
}
}
+ for (i = 0; matches[i]; i++)
+ free(matches[i]);
free(matches);
}