From c9e2d4794c224cb0b246f86ed7baae8f7860c35f Mon Sep 17 00:00:00 2001 From: Jacek Jendrzej Date: Sat, 6 Feb 2016 15:19:18 +0100 Subject: [PATCH] src/driver/record.cpp check avformat_write_header return Origin commit data ------------------ Branch: ni/coolstream Commit: https://github.com/neutrino-images/ni-neutrino/commit/2e602c0c950995fbbe0700e9b50312503ea6c4be Author: Jacek Jendrzej Date: 2016-02-06 (Sat, 06 Feb 2016) ------------------ No further description and justification available within origin commit message! ------------------ This commit was generated by Migit --- src/driver/record.cpp | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/src/driver/record.cpp b/src/driver/record.cpp index 7aedd725d..f30957262 100644 --- a/src/driver/record.cpp +++ b/src/driver/record.cpp @@ -2128,7 +2128,10 @@ void CStreamRec::run() time_t tstart = time_monotonic(); time_started = tstart; start_time = time(0); - avformat_write_header(ofcx, NULL); + if (avformat_write_header(ofcx, NULL) < 0) { + printf("%s: avformat_write_header failed\n", __FUNCTION__); + return; + } double total = 0; while (!stopped) {