Skip to content

Commit a5e1c73

Browse files
committed
Merge pull request #202 from cchampet/fix_GhostThreadInPyThumbnail
Fix ghost thread in pythumbnail
2 parents 3f96a67 + 52a672a commit a5e1c73

File tree

2 files changed

+7
-6
lines changed

2 files changed

+7
-6
lines changed

src/AvTranscoder/codec/ICodec.cpp

Lines changed: 6 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -43,12 +43,13 @@ ICodec::ICodec( const ECodecType type, AVCodecContext& avCodecContext )
4343

4444
ICodec::~ICodec()
4545
{
46-
if( ! _isCodecContextAllocated )
47-
return;
46+
avcodec_close(_avCodecContext);
47+
48+
if(!_isCodecContextAllocated)
49+
return;
4850

49-
avcodec_close( _avCodecContext );
50-
av_free( _avCodecContext );
51-
_avCodecContext = NULL;
51+
av_free(_avCodecContext);
52+
_avCodecContext = NULL;
5253
}
5354

5455
void ICodec::openCodec()

src/AvTranscoder/common.hpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33

44
#define AVTRANSCODER_VERSION_MAJOR 0
55
#define AVTRANSCODER_VERSION_MINOR 6
6-
#define AVTRANSCODER_VERSION_MICRO 1
6+
#define AVTRANSCODER_VERSION_MICRO 2
77

88
#include <AvTranscoder/system.hpp>
99

0 commit comments

Comments
 (0)