On Wed, Feb 4, 2015 at 7:49 PM, Diego Biurrun <[email protected]> wrote: > On Wed, Feb 04, 2015 at 02:21:01PM +0000, Vittorio Giovara wrote: >> --- a/avplay.c >> +++ b/avplay.c >> @@ -2257,6 +2257,11 @@ static int decode_thread(void *arg) >> global_video_state = is; >> >> ic = avformat_alloc_context(); >> + if (!ic) { >> + av_log(NULL, AV_LOG_FATAL, "Could not allocate context.\n"); > > fprintf? That function needs to make up its mind about what way to use > to print errors.
I'd go with the colored av_log :) > IMO this should be squashed with 2/4. If we have one commit per unchecked > malloc we'll add (what feels like) thousands of commits before we're done. Normally I am all for squashing, but 2/4 addresses frame allocation, while this one fromat context allocation, so abeit very similar I'd rather go for keeping them distinct. -- Vittorio _______________________________________________ libav-devel mailing list [email protected] https://lists.libav.org/mailman/listinfo/libav-devel
