]> git.ipfire.org Git - thirdparty/asterisk.git/commitdiff
Merged revisions 238412 via svnmerge from
authorDavid Vossel <dvossel@digium.com>
Thu, 7 Jan 2010 20:22:50 +0000 (20:22 +0000)
committerDavid Vossel <dvossel@digium.com>
Thu, 7 Jan 2010 20:22:50 +0000 (20:22 +0000)
https://origsvn.digium.com/svn/asterisk/trunk

................
  r238412 | dvossel | 2010-01-07 14:15:27 -0600 (Thu, 07 Jan 2010) | 16 lines

  Merged revisions 238411 via svnmerge from
  https://origsvn.digium.com/svn/asterisk/branches/1.4

  ........
    r238411 | dvossel | 2010-01-07 14:14:25 -0600 (Thu, 07 Jan 2010) | 10 lines

    fixes crash in "scheduled_destroy" in chan_iax

    A signed short was used to represent a callnumber.  This is makes
    it possible to attempt to access the iaxs array with a negative
    index.

    (closes issue #16565)
    Reported by: jensvb
  ........
................

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

channels/chan_iax2.c

index dcd4a17dd72f0fbff936a313c212e261627809a1..d5429d7cf0a7a356949386940e33671c80b29781 100644 (file)
@@ -1509,7 +1509,7 @@ static void iax2_frame_free(struct iax_frame *fr)
 
 static int scheduled_destroy(const void *vid)
 {
-       short callno = PTR_TO_CALLNO(vid);
+       unsigned short callno = PTR_TO_CALLNO(vid);
        ast_mutex_lock(&iaxsl[callno]);
        if (iaxs[callno]) {
                if (option_debug) {