Commit 86042de8 authored by Martin Storsjö's avatar Martin Storsjö

rtpdec_h264: Pass NAL type 0 through

According to the spec, this type shouldn't ever be used. Nevertheless,
passing it through enables decoding streams which otherwise aren't
decodeable.

Originally committed as revision 25897 to svn://svn.ffmpeg.org/ffmpeg/trunk
parent 4838cdab
...@@ -187,10 +187,7 @@ static int h264_handle_packet(AVFormatContext *ctx, ...@@ -187,10 +187,7 @@ static int h264_handle_packet(AVFormatContext *ctx,
if (type >= 1 && type <= 23) if (type >= 1 && type <= 23)
type = 1; // simplify the case. (these are all the nal types used internally by the h264 codec) type = 1; // simplify the case. (these are all the nal types used internally by the h264 codec)
switch (type) { switch (type) {
case 0: // undefined; case 0: // undefined, but pass them through
result= -1;
break;
case 1: case 1:
av_new_packet(pkt, len+sizeof(start_sequence)); av_new_packet(pkt, len+sizeof(start_sequence));
memcpy(pkt->data, start_sequence, sizeof(start_sequence)); memcpy(pkt->data, start_sequence, sizeof(start_sequence));
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment