• Anton Khirnov's avatar
    lavf: fall back to a more meaningful log instance name · dffb058f
    Anton Khirnov authored
    An uninitialized AVFormatContext instance with neither iformat nor
    oformat set will currently log as 'NULL', which is confusing and
    unhelpful. Print 'AVFormatContext' instead, which provides more
    information.
    
    This happens e.g. if choosing an output format fails in
    avformat_alloc_output_context2().
    
    E.g. with the following commandline:
     ffmpeg -i <input> -f foobar -y /dev/null
    before: [NULL @ 0x5580377834c0] Requested output format 'foobar' is not a suitable output format
    after:  [AVFormatContext @ 0x55fa15bb34c0] Requested output format 'foobar' is not a suitable output format
    dffb058f
options.c 11.2 KB