Bug in multipart creation

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

 



I attempted to use the library to send an INVITE message with multipart content.  I created the multipart container by calling pjsip_multipart_create with NULL for the ctype argument, indicating the default "multipart/mixed" should be used.  Later when the print method is called, a crash occurs.  It appears to be a problem with the way the linked list of content-type parameters is initialized.

The following patch has resolved my problem:


Index: sip_multipart.c
===================================================================
--- sip_multipart.c     (revision 3362)
+++ sip_multipart.c     (working copy)
@@ -231,6 +231,8 @@

        body->content_type.type = STR_MULTIPART;
        body->content_type.subtype = STR_MIXED;
+       body->content_type.param.next = &body->content_type.param;
+       body->content_type.param.prev = &body->content_type.param;
     }

     /* multipart data */





[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