aboutsummaryrefslogtreecommitdiffstats
path: root/pbx.c
diff options
context:
space:
mode:
authorcitats <citats@f38db490-d61c-443f-a65b-d21fe96a405b>2004-02-23 02:47:22 +0000
committercitats <citats@f38db490-d61c-443f-a65b-d21fe96a405b>2004-02-23 02:47:22 +0000
commitaf3fd0b55d9dea49bc0b8170c396f86b3aa87901 (patch)
treeb4bc1e4958406f0d0d22749f51a7c3677aefcb72 /pbx.c
parent74cef7a888f7874cd79c4ede97f56b50dc78212a (diff)
Fix ast_add_extension2 updating ast_exten correctly in certain cases
where extensions.conf is not ordered numerically by priority (bug #1065) git-svn-id: http://svn.digium.com/svn/asterisk/trunk@2215 f38db490-d61c-443f-a65b-d21fe96a405b
Diffstat (limited to 'pbx.c')
-rwxr-xr-xpbx.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/pbx.c b/pbx.c
index 7e35f0032..106091d27 100755
--- a/pbx.c
+++ b/pbx.c
@@ -3732,9 +3732,9 @@ int ast_add_extension2(struct ast_context *con,
tmp->peer = e;
} else {
/* We're the very first extension altogether */
- tmp->next = con->root;
+ tmp->next = con->root->next;
/* Con->root must always exist or we couldn't get here */
- tmp->peer = con->root->peer;
+ tmp->peer = con->root;
con->root = tmp;
}
ast_mutex_unlock(&con->lock);