Commit e79309fd authored by Andreas Rheinhardt's avatar Andreas Rheinhardt

libavformat/mux, mxfenc: Don't initialize unnecessarily

When no packet could be output, the interleavement functions
nevertheless initialized the packet destined for output (with the
exception of the data and size fields, making the initialization
pointless), although it will not be used at all. So remove the
initializations.
Reviewed-by: 's avatarMarton Balint <cus@passwd.hu>
Signed-off-by: 's avatarAndreas Rheinhardt <andreas.rheinhardt@gmail.com>
parent 148bcc0b
......@@ -503,8 +503,8 @@ int ff_read_packet(AVFormatContext *s, AVPacket *pkt);
* @param pkt the input packet; will be blank on return if not NULL
* @param flush 1 if no further packets are available as input and all
* remaining packets should be output
* @return 1 if a packet was output, 0 if no packet could be output,
* < 0 if an error occurred
* @return 1 if a packet was output, 0 if no packet could be output
* (in which case out may be uninitialized), < 0 if an error occurred
*/
int ff_interleave_packet_per_dts(AVFormatContext *s, AVPacket *out,
AVPacket *pkt, int flush);
......
......@@ -1144,7 +1144,6 @@ int ff_interleave_packet_per_dts(AVFormatContext *s, AVPacket *out,
return 1;
} else {
av_init_packet(out);
return 0;
}
}
......
......@@ -3070,7 +3070,6 @@ static int mxf_interleave_get_packet(AVFormatContext *s, AVPacket *out, AVPacket
return 1;
} else {
out:
av_init_packet(out);
return 0;
}
}
......
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