Revision a7827a17 libavformat/mpegtsenc.c

View differences:

libavformat/mpegtsenc.c
128 128
{
129 129
    uint8_t section[1024], *q;
130 130
    unsigned int tot_len;
131
    /* reserved_future_use field must be set to 1 for SDT */
132
    unsigned int flags = tid == SDT_TID ? 0xf000 : 0xb000;
131 133

  
132 134
    tot_len = 3 + 5 + len + 4;
133 135
    /* check if not too big */
......
136 138

  
137 139
    q = section;
138 140
    *q++ = tid;
139
    put16(&q, 0xb000 | (len + 5 + 4)); /* 5 byte header + 4 byte CRC */
141
    put16(&q, flags | (len + 5 + 4)); /* 5 byte header + 4 byte CRC */
140 142
    put16(&q, id);
141 143
    *q++ = 0xc1 | (version << 1); /* current_next_indicator = 1 */
142 144
    *q++ = sec_num;

Also available in: Unified diff