mirror of
https://github.com/FFmpeg/FFmpeg.git
synced 2025-04-24 17:12:34 +02:00
smoothstreamingenc: Check the output UrlContext before accessing it
This code can be called with a NULL UrlContext if writing of the trailer involves seeking. Signed-off-by: Martin Storsjö <martin@martin.st>
This commit is contained in:
parent
d3a72becc6
commit
eb2f391018
@ -108,6 +108,7 @@ static int64_t ism_seek(void *opaque, int64_t offset, int whence)
|
|||||||
os->tail_out = NULL;
|
os->tail_out = NULL;
|
||||||
}
|
}
|
||||||
if (offset >= os->cur_start_pos) {
|
if (offset >= os->cur_start_pos) {
|
||||||
|
if (os->out)
|
||||||
ffurl_seek(os->out, offset - os->cur_start_pos, SEEK_SET);
|
ffurl_seek(os->out, offset - os->cur_start_pos, SEEK_SET);
|
||||||
os->cur_pos = offset;
|
os->cur_pos = offset;
|
||||||
return offset;
|
return offset;
|
||||||
|
Loading…
x
Reference in New Issue
Block a user