[asterisk-commits] mmichelson: branch mmichelson/issue14220 r168982 - /team/mmichelson/issue14220/

SVN commits to the Asterisk project asterisk-commits at lists.digium.com
Fri Jan 16 17:06:05 CST 2009


Author: mmichelson
Date: Fri Jan 16 17:06:04 2009
New Revision: 168982

URL: http://svn.digium.com/svn-view/asterisk?view=rev&rev=168982
Log:
Creating a new branch to fix issue #14220

The problem arose when chan_sip converted its sip_request to use
an expandable ast_str structure instead of using a statically-sized
buffer.

A sip_request structure maintains two arrays of character pointers, called
header and line. These point to each individual header or SDP line in the
SIP request. The problem that this branch will be addressing is that when
an ast_str expands to hold more data, the header and line pointers are then
pointing to invalid memory.

The plan of action here is to change the header and line arrays to contain
offsets into the ast_str struct instead character pointers. This way, if the
ast_str is reallocated to allow for more data to be stored inside, the same
offsets can be applied to the newly allocated area and all will be well.


Added:
    team/mmichelson/issue14220/
      - copied from r168980, trunk/




More information about the asterisk-commits mailing list