]> git.ipfire.org Git - thirdparty/asterisk.git/commitdiff
Don't try to unlock a bogus channel.
authorRussell Bryant <russell@russellbryant.com>
Mon, 18 May 2009 12:57:46 +0000 (12:57 +0000)
committerRussell Bryant <russell@russellbryant.com>
Mon, 18 May 2009 12:57:46 +0000 (12:57 +0000)
(closes issue #15144)
Reported by: cristiandimache

git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.4@195020 65c4cc65-6c06-0410-ace0-fbb531ad65f3

main/manager.c

index d54874547922bf9cd47bf6a4aa3ae811679bd4e4..93fcd5a349c365005606ed25b2e5c50fe68af022 100644 (file)
@@ -1550,6 +1550,7 @@ static int action_getvar(struct mansession *s, const struct message *m)
                        if (c) {
                                ast_func_read(c, copy, workspace, sizeof(workspace));
                                ast_channel_free(c);
+                               c = NULL;
                        } else
                                ast_log(LOG_ERROR, "Unable to allocate bogus channel for variable substitution.  Function results may be blank.\n");
                } else