Commit d5f4857a authored by JULIAN GARDNER's avatar JULIAN GARDNER Committed by Michael Niedermayer

dvbsubdec:dvbsub_display_end_segment() move main loop under if() as its useless if false.

Signed-off-by: 's avatarMichael Niedermayer <michaelni@gmx.at>
parent 5a563c63
...@@ -1376,13 +1376,11 @@ static int dvbsub_display_end_segment(AVCodecContext *avctx, const uint8_t *buf, ...@@ -1376,13 +1376,11 @@ static int dvbsub_display_end_segment(AVCodecContext *avctx, const uint8_t *buf,
sub->rects = av_mallocz(sizeof(*sub->rects) * sub->num_rects); sub->rects = av_mallocz(sizeof(*sub->rects) * sub->num_rects);
for(i=0; i<sub->num_rects; i++) for(i=0; i<sub->num_rects; i++)
sub->rects[i] = av_mallocz(sizeof(*sub->rects[i])); sub->rects[i] = av_mallocz(sizeof(*sub->rects[i]));
}
i = 0; i = 0;
for (display = ctx->display_list; display; display = display->next) { for (display = ctx->display_list; display; display = display->next) {
region = get_region(ctx, display->region_id); region = get_region(ctx, display->region_id);
rect = sub->rects[i];
if (!region) if (!region)
continue; continue;
...@@ -1427,7 +1425,7 @@ static int dvbsub_display_end_segment(AVCodecContext *avctx, const uint8_t *buf, ...@@ -1427,7 +1425,7 @@ static int dvbsub_display_end_segment(AVCodecContext *avctx, const uint8_t *buf,
} }
sub->num_rects = i; sub->num_rects = i;
}
#ifdef DEBUG #ifdef DEBUG
save_display_set(ctx); save_display_set(ctx);
#endif #endif
......
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