]> git.ipfire.org Git - thirdparty/asterisk.git/commitdiff
prevent a warning for uninitialized variable.
authorLuigi Rizzo <rizzo@icir.org>
Wed, 10 May 2006 07:13:23 +0000 (07:13 +0000)
committerLuigi Rizzo <rizzo@icir.org>
Wed, 10 May 2006 07:13:23 +0000 (07:13 +0000)
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@26281 65c4cc65-6c06-0410-ace0-fbb531ad65f3

pbx.c

diff --git a/pbx.c b/pbx.c
index bdd62dd0ea70a13a0691ca2906f8e86acf9a3625..0aaea68cce611a91ded638c457f2e5ba786a9765 100644 (file)
--- a/pbx.c
+++ b/pbx.c
@@ -4346,6 +4346,7 @@ int ast_add_extension2(struct ast_context *con,
        tmp->registrar = registrar;
 
        ast_mutex_lock(&con->lock);
+       res = 0; /* some compilers will think it is uninitialized otherwise */
        for (e = con->root; e; el = e, e = e->next) {   /* scan the extension list */
                res = ext_cmp(e->exten, extension);
                if (res == 0) { /* extension match, now look at cidmatch */