Commit 7bac6e5c authored by Stefano Sabatini's avatar Stefano Sabatini

ffprobe: fix uninitialized variable warning

Fix warning:
ffprobe.c:1684:21: warning: ‘start’ may be used uninitialized in this function [-Wmaybe-uninitialized] end = start + interval->end;

The warning is a false positive, since the variable is accessed only if
has_start is set, and in that case start has been already set.
parent c74fa39b
......@@ -1636,7 +1636,7 @@ static int read_interval_packets(WriterContext *w, AVFormatContext *fmt_ctx,
AVPacket pkt, pkt1;
AVFrame frame;
int ret = 0, i = 0, frame_count = 0;
int64_t start, end = interval->end;
int64_t start = -INT64_MAX, end = interval->end;
int has_start = 0, has_end = interval->has_end && !interval->end_is_offset;
av_init_packet(&pkt);
......
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