how to do tcp connection reused for pjsip

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



hi,all:

I setup a tcp connection form client to a server,

and remember this connection to the server , requestion of the server
reused  it send to client ,too,

this requirement is writted in draft-ietf-sip-connect-reuse-03 , it's added
"alias" in the field "via" ,

for example:


Via: SIP/2.0/TCP 192.168.0.225:5060;branch=z9hG4bKa7;alias


by review pjsip code ,  the struct of the field "via" is:


typedef struct pjsip_via_hdr
{
    PJSIP_DECL_HDR_MEMBER(struct pjsip_via_hdr);
    pj_str_t         transport;        /**< Transport type. */
    pjsip_host_port  sent_by;        /**< Host and optional port */
    int             ttl_param;        /**< TTL parameter, or -1 if it's not
specified. */
    int             rport_param;   /**< "rport" parameter, 0 to specify
without
                     port number, -1 means doesn't exist. */
    pj_str_t         maddr_param;   /**< "maddr" parameter. */
    pj_str_t         recvd_param;   /**< "received" parameter. */
    pj_str_t         branch_param;  /**< "branch" parameter. */
    pjsip_param         other_param;   /**< Other parameters, concatenated
as single string. */
    pj_str_t         comment;        /**< Comment. */
} pjsip_via_hdr;


typedef struct pjsip_param
{
    PJ_DECL_LIST_MEMBER(struct pjsip_param);    /**< Generic list member.
*/
    pj_str_t        name;            /**< Param/header name.        */
    pj_str_t        value;            /**< Param/header value.    */
} pjsip_param;


after i used the "other_param" , it changed

:Via: SIP/2.0/TCP 192.168.0.225:5060;branch=z9hG4bKa7;alias=alias,

or not fail, i can't add this param "alias" in the field.......

how to add this param "alias" to the field "via",
or how to do tcp connection reuserd for pjsip by other ways ?




Regards,
-- 
Liszt
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.pjsip.org/pipermail/pjsip_lists.pjsip.org/attachments/20090320/e0562189/attachment.html>


[Index of Archives]     [Asterisk Users]     [Asterisk App Development]     [Linux ARM Kernel]     [Linux ARM]     [Linux Omap]     [Fedora ARM]     [IETF Annouce]     [Security]     [Bugtraq]     [Linux]     [Linux OMAP]     [Linux MIPS]     [Linux API]
  Powered by Linux