Ignore:
Timestamp:
Feb 19, 2006 3:35:54 PM (18 years ago)
Author:
bennylp
Message:

Fixed packing error in rtp header, and sdp validation supports non numeric pt for broken uas

File:
1 edited

Legend:

Unmodified
Added
Removed
  • pjproject/trunk/pjmedia/include/pjmedia/rtp.h

    r188 r199  
    7171 
    7272 
     73 
     74/** 
     75 * RTP packet header. 
     76 */ 
    7377#pragma pack(1) 
    74  
    75 /** 
    76  * RTP packet header. 
    77  */ 
    7878struct pjmedia_rtp_hdr 
    7979{ 
    8080#if defined(PJ_IS_BIG_ENDIAN) && (PJ_IS_BIG_ENDIAN!=0) 
    81     int v:2;            /**< packet type/version            */ 
    82     int p:1;            /**< padding flag                   */ 
    83     int x:1;            /**< extension flag                 */ 
    84     int cc:4;           /**< CSRC count                     */ 
    85     int m:1;            /**< marker bit                     */ 
    86     int pt:7;           /**< payload type                   */ 
     81    pj_uint16_t v:2;            /**< packet type/version            */ 
     82    pj_uint16_t p:1;            /**< padding flag                   */ 
     83    pj_uint16_t x:1;            /**< extension flag                 */ 
     84    pj_uint16_t cc:4;           /**< CSRC count                     */ 
     85    pj_uint16_t m:1;            /**< marker bit                     */ 
     86    pj_uint16_t pt:7;           /**< payload type                   */ 
    8787#else 
    88     int cc:4;           /**< CSRC count                     */ 
    89     int x:1;            /**< header extension flag          */  
    90     int p:1;            /**< padding flag                   */ 
    91     int v:2;            /**< packet type/version            */ 
    92     int pt:7;           /**< payload type                   */ 
    93     int m:1;            /**< marker bit                     */ 
     88    pj_uint16_t cc:4;           /**< CSRC count                     */ 
     89    pj_uint16_t x:1;            /**< header extension flag          */  
     90    pj_uint16_t p:1;            /**< padding flag                   */ 
     91    pj_uint16_t v:2;            /**< packet type/version            */ 
     92    pj_uint16_t pt:7;           /**< payload type                   */ 
     93    pj_uint16_t m:1;            /**< marker bit                     */ 
    9494#endif 
    95     pj_uint16_t seq;    /**< sequence number                */ 
    96     pj_uint32_t ts;     /**< timestamp                      */ 
    97     pj_uint32_t ssrc;   /**< synchronization source         */ 
    98 }; 
    99  
     95    pj_uint16_t seq;            /**< sequence number                */ 
     96    pj_uint32_t ts;             /**< timestamp                      */ 
     97    pj_uint32_t ssrc;           /**< synchronization source         */ 
     98}; 
    10099#pragma pack() 
    101100 
Note: See TracChangeset for help on using the changeset viewer.