Skip to content

Commit be100b8

Browse files
committed
Fix: don't unref and free audio filters data twice
1 parent f32fc13 commit be100b8

File tree

1 file changed

+6
-6
lines changed

1 file changed

+6
-6
lines changed

src/AvTranscoder/transcoder/StreamTranscoder.cpp

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -751,6 +751,12 @@ IOutputStream::EWrappingStatus StreamTranscoder::processTranscode()
751751
_transformedData->allocateData();
752752
}
753753
}
754+
else if(_filterGraph->hasFilters())
755+
{
756+
LOG_DEBUG("Free filtered data") // filled from filter graph sink
757+
av_frame_unref(&_filteredData->getAVFrame());
758+
_filteredData->freeData();
759+
}
754760

755761
// Check decoding status
756762
bool continueProcess = true;
@@ -805,12 +811,6 @@ IOutputStream::EWrappingStatus StreamTranscoder::processTranscode()
805811
LOG_DEBUG("Encode")
806812
_outputEncoder->encodeFrame(*_transformedData, data);
807813

808-
if(_filterGraph->hasFilters())
809-
{
810-
LOG_DEBUG("Free filtered data") // filled from filter graph sink
811-
av_frame_unref(&_filteredData->getAVFrame());
812-
_filteredData->freeData();
813-
}
814814
}
815815
else
816816
{

0 commit comments

Comments
 (0)
pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy