CID:1214231 don't leak when using invalid syntax

This commit is contained in:
Michael Jerris 2014-05-15 12:27:39 +00:00
parent bdbefdcc48
commit 622cd21009
1 changed files with 1 additions and 0 deletions

View File

@ -1420,6 +1420,7 @@ SWITCH_STANDARD_API(expand_function)
if (zstr(mycmd)) { if (zstr(mycmd)) {
stream->write_function(stream, "-ERR No input\n"); stream->write_function(stream, "-ERR No input\n");
switch_safe_free(dup);
return SWITCH_STATUS_SUCCESS; return SWITCH_STATUS_SUCCESS;
} }