Skip to content

Commit 5cf858d

Browse files
author
Clement Champetier
committed
InputFile: fix build of getFormatMimeType() when libavformat <= 55
1 parent c5fcc68 commit 5cf858d

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed

src/AvTranscoder/file/InputFile.cpp

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -133,6 +133,11 @@ std::string InputFile::getFormatLongName() const
133133

134134
std::string InputFile::getFormatMimeType() const
135135
{
136+
#if LIBAVFORMAT_VERSION_MAJOR <= 55
137+
LOG_WARN("Cannot get mime type format of '" << _filename << "' because your libavformat library has a major version <= 55.")
138+
return "not available";
139+
#endif
140+
136141
if( _formatContext.getAVInputFormat().mime_type == NULL )
137142
return "unknown";
138143
return std::string(_formatContext.getAVInputFormat().mime_type);

0 commit comments

Comments
 (0)