diff options
author | James Almer <jamrial@gmail.com> | 2017-11-11 13:55:35 -0300 |
---|---|---|
committer | James Almer <jamrial@gmail.com> | 2017-11-11 13:55:35 -0300 |
commit | 460e7596cb5b1a449e50a7c3d2e6a5fff4a94c9a (patch) | |
tree | 07a1331e12eea31e8e04b9849f1f54c16e8a1af9 | |
parent | 4c01fa0bc5ac5a7d9d9576cf669a1deb58e75af8 (diff) | |
parent | f19fbfbdc637e08ad5c980807ede2d023f20c049 (diff) | |
download | ffmpeg-460e7596cb5b1a449e50a7c3d2e6a5fff4a94c9a.tar.gz |
Merge commit 'f19fbfbdc637e08ad5c980807ede2d023f20c049'
* commit 'f19fbfbdc637e08ad5c980807ede2d023f20c049':
aviocat: Check for output write errors
Merged-by: James Almer <jamrial@gmail.com>
-rw-r--r-- | tools/aviocat.c | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/tools/aviocat.c b/tools/aviocat.c index 983108a64a..28529b06d6 100644 --- a/tools/aviocat.c +++ b/tools/aviocat.c @@ -107,6 +107,11 @@ int main(int argc, char **argv) if (n <= 0) break; avio_write(output, buf, n); + if (output->error) { + av_strerror(output->error, errbuf, sizeof(errbuf)); + fprintf(stderr, "Unable to write %s: %s\n", output_url, errbuf); + break; + } stream_pos += n; if (bps) { avio_flush(output); |