mirror of
https://gitlab.freedesktop.org/pulseaudio/pulseaudio.git
synced 2025-11-06 13:29:56 -05:00
make rtp.h ANSI C compliant
This commit is contained in:
parent
e412f1cde3
commit
62f1f3e563
1 changed files with 22 additions and 22 deletions
|
|
@ -24,13 +24,13 @@
|
|||
#if __BYTE_ORDER == __LITTLE_ENDIAN
|
||||
|
||||
struct rtp_header {
|
||||
uint8_t cc:4;
|
||||
uint8_t x:1;
|
||||
uint8_t p:1;
|
||||
uint8_t v:2;
|
||||
unsigned cc:4;
|
||||
unsigned x:1;
|
||||
unsigned p:1;
|
||||
unsigned v:2;
|
||||
|
||||
uint8_t pt:7;
|
||||
uint8_t m:1;
|
||||
unsigned pt:7;
|
||||
unsigned m:1;
|
||||
|
||||
uint16_t sequence_number;
|
||||
uint32_t timestamp;
|
||||
|
|
@ -39,23 +39,23 @@ struct rtp_header {
|
|||
} __attribute__ ((packed));
|
||||
|
||||
struct rtp_payload {
|
||||
uint8_t frame_count:4;
|
||||
uint8_t rfa0:1;
|
||||
uint8_t is_last_fragment:1;
|
||||
uint8_t is_first_fragment:1;
|
||||
uint8_t is_fragmented:1;
|
||||
unsigned frame_count:4;
|
||||
unsigned rfa0:1;
|
||||
unsigned is_last_fragment:1;
|
||||
unsigned is_first_fragment:1;
|
||||
unsigned is_fragmented:1;
|
||||
} __attribute__ ((packed));
|
||||
|
||||
#elif __BYTE_ORDER == __BIG_ENDIAN
|
||||
|
||||
struct rtp_header {
|
||||
uint8_t v:2;
|
||||
uint8_t p:1;
|
||||
uint8_t x:1;
|
||||
uint8_t cc:4;
|
||||
unsigned v:2;
|
||||
unsigned p:1;
|
||||
unsigned x:1;
|
||||
unsigned cc:4;
|
||||
|
||||
uint8_t m:1;
|
||||
uint8_t pt:7;
|
||||
unsigned m:1;
|
||||
unsigned pt:7;
|
||||
|
||||
uint16_t sequence_number;
|
||||
uint32_t timestamp;
|
||||
|
|
@ -64,11 +64,11 @@ struct rtp_header {
|
|||
} __attribute__ ((packed));
|
||||
|
||||
struct rtp_payload {
|
||||
uint8_t is_fragmented:1;
|
||||
uint8_t is_first_fragment:1;
|
||||
uint8_t is_last_fragment:1;
|
||||
uint8_t rfa0:1;
|
||||
uint8_t frame_count:4;
|
||||
unsigned is_fragmented:1;
|
||||
unsigned is_first_fragment:1;
|
||||
unsigned is_last_fragment:1;
|
||||
unsigned rfa0:1;
|
||||
unsigned frame_count:4;
|
||||
} __attribute__ ((packed));
|
||||
|
||||
#else
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue