]> git.ipfire.org Git - thirdparty/asterisk.git/commit
Fix a SIP request memory leak with TLS connections.
authorJoshua Colp <jcolp@digium.com>
Wed, 5 Dec 2012 16:50:43 +0000 (16:50 +0000)
committerJoshua Colp <jcolp@digium.com>
Wed, 5 Dec 2012 16:50:43 +0000 (16:50 +0000)
commiteb3a88351a5576ca07797ca19674eb35602dafa2
tree32bf58ca93f40852f4d4a52a1b683ca1dac59c9f
parentb40ac293b6afe7bdffeebf54a3513ec2f10e133e
Fix a SIP request memory leak with TLS connections.

During the TLS re-work in chan_sip some TLS specific code was moved
into a separate function. This function operates on a copy of the
incoming SIP request. This copy was never deinitialized causing a
memory leak for each request processed.

This function is now given a SIP request structure which it can use
to copy the incoming request into. This reduces the amount of memory
allocations done since the internal allocated components are reused
between packets and also ensures the SIP request structure is
deinitialized when the TLS connection is torn down.

(closes issue ASTERISK-20763)
Reported by: deti
........

Merged revisions 377257 from http://svn.asterisk.org/svn/asterisk/branches/1.8
........

Merged revisions 377258 from http://svn.asterisk.org/svn/asterisk/branches/10

git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/11@377259 65c4cc65-6c06-0410-ace0-fbb531ad65f3
channels/chan_sip.c