Merged revisions 131491 via svnmerge from
authorBrett Bryant <bbryant@digium.com>
Wed, 16 Jul 2008 22:17:36 +0000 (22:17 +0000)
committerBrett Bryant <bbryant@digium.com>
Wed, 16 Jul 2008 22:17:36 +0000 (22:17 +0000)
https://origsvn.digium.com/svn/asterisk/branches/1.4

........
r131491 | bbryant | 2008-07-16 17:17:07 -0500 (Wed, 16 Jul 2008) | 6 lines

Fix a bug in iax2 registration that allowed peers to register with
case-insensitive names (user_cmp_cb and peer_cmp_cb are now both
case-sensitive).

(closes issue #13091)

........

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

channels/chan_iax2.c

index 06404dd..45ecffc 100644 (file)
@@ -1270,7 +1270,7 @@ static int peer_cmp_cb(void *obj, void *arg, int flags)
 {
        struct iax2_peer *peer = obj, *peer2 = arg;
 
-       return !strcasecmp(peer->name, peer2->name) ? CMP_MATCH : 0;
+       return !strcmp(peer->name, peer2->name) ? CMP_MATCH : 0;
 }
 
 /*!
@@ -1290,7 +1290,7 @@ static int user_cmp_cb(void *obj, void *arg, int flags)
 {
        struct iax2_user *user = obj, *user2 = arg;
 
-       return !strcasecmp(user->name, user2->name) ? CMP_MATCH : 0;
+       return !strcmp(user->name, user2->name) ? CMP_MATCH : 0;
 }
 
 /*!