mirror of
https://github.com/mpv-player/mpv.git
synced 2025-12-28 05:33:14 +00:00
stream: provide a stream_get_size() convenience function
And use it everywhere, instead of retrieving the size manually. Slight simplification.
This commit is contained in:
@@ -208,8 +208,7 @@ int stream_dump(struct MPContext *mpctx, const char *source_filename)
|
||||
if (!stream)
|
||||
return -1;
|
||||
|
||||
int64_t size = 0;
|
||||
stream_control(stream, STREAM_CTRL_GET_SIZE, &size);
|
||||
int64_t size = stream_get_size(stream);
|
||||
|
||||
stream_set_capture_file(stream, opts->stream_dump);
|
||||
|
||||
|
||||
Reference in New Issue
Block a user