mirror of https://git.ffmpeg.org/ffmpeg.git
avformat/movenc: remove one level of indentation
Signed-off-by: James Almer <jamrial@gmail.com>
This commit is contained in:
parent
63702d5f9c
commit
ce33a5f16d
|
@ -6672,6 +6672,7 @@ static int mov_write_subtitle_end_packet(AVFormatContext *s,
|
|||
#if CONFIG_IAMFENC
|
||||
static int mov_build_iamf_packet(AVFormatContext *s, MOVTrack *trk, AVPacket *pkt)
|
||||
{
|
||||
uint8_t *data;
|
||||
int ret;
|
||||
|
||||
if (pkt->stream_index == trk->first_iamf_idx) {
|
||||
|
@ -6685,12 +6686,11 @@ static int mov_build_iamf_packet(AVFormatContext *s, MOVTrack *trk, AVPacket *pk
|
|||
if (ret < 0)
|
||||
return ret;
|
||||
|
||||
if (pkt->stream_index == trk->last_iamf_idx) {
|
||||
uint8_t *data;
|
||||
if (pkt->stream_index != trk->last_iamf_idx)
|
||||
return AVERROR(EAGAIN);
|
||||
|
||||
ret = avio_close_dyn_buf(trk->iamf_buf, &data);
|
||||
trk->iamf_buf = NULL;
|
||||
|
||||
if (!ret) {
|
||||
if (pkt->size) {
|
||||
// Either all or none of the packets for a single
|
||||
|
@ -6702,6 +6702,7 @@ static int mov_build_iamf_packet(AVFormatContext *s, MOVTrack *trk, AVPacket *pk
|
|||
av_free(data);
|
||||
return ret;
|
||||
}
|
||||
|
||||
av_buffer_unref(&pkt->buf);
|
||||
pkt->buf = av_buffer_create(data, ret, NULL, NULL, 0);
|
||||
if (!pkt->buf) {
|
||||
|
@ -6712,13 +6713,7 @@ static int mov_build_iamf_packet(AVFormatContext *s, MOVTrack *trk, AVPacket *pk
|
|||
pkt->size = ret;
|
||||
pkt->stream_index = trk->first_iamf_idx;
|
||||
|
||||
ret = avio_open_dyn_buf(&trk->iamf_buf);
|
||||
if (ret < 0)
|
||||
return ret;
|
||||
} else
|
||||
ret = AVERROR(EAGAIN);
|
||||
|
||||
return ret;
|
||||
return avio_open_dyn_buf(&trk->iamf_buf);
|
||||
}
|
||||
#endif
|
||||
|
||||
|
|
Loading…
Reference in New Issue