]> git.ipfire.org Git - thirdparty/asterisk.git/commitdiff
Add a couple more missing unrefs of queue member objects
authorRussell Bryant <russell@russellbryant.com>
Tue, 11 Sep 2007 14:34:12 +0000 (14:34 +0000)
committerRussell Bryant <russell@russellbryant.com>
Tue, 11 Sep 2007 14:34:12 +0000 (14:34 +0000)
git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.4@82240 65c4cc65-6c06-0410-ace0-fbb531ad65f3

apps/app_queue.c

index 9c973e082c8744e467b7c636a20db1e6cc6003d6..ac12f89e37fa32ef75dfc98f69671d2425bdd69e 100644 (file)
@@ -3773,6 +3773,7 @@ static int queue_function_queuememberlist(struct ast_channel *chan, char *cmd, c
                        buflen += strlen(m->interface);
                        /* Safeguard against overflow (negative length) */
                        if (buflen >= len - 2) {
+                               ao2_ref(m, -1);
                                ast_log(LOG_WARNING, "Truncating list\n");
                                break;
                        }
@@ -4520,6 +4521,7 @@ static char *complete_queue_remove_member(const char *line, const char *word, in
                                        ao2_ref(m, -1);
                                        return tmp;
                                }
+                               ao2_ref(m, -1);
                        }
                        ast_mutex_unlock(&q->lock);
                }