Permalink
Browse files

fix mem leak if ffmpeg calls get_format more than once

  • Loading branch information...
1 parent 57ba0cb commit b0bcef1771ccdd643b719bf0f61a5fb55ae7fb27 @FernetMenta FernetMenta committed Nov 16, 2011
Showing with 1 addition and 0 deletions.
  1. +1 −0 xbmc/cores/dvdplayer/DVDCodecs/Video/DVDVideoCodecFFmpeg.h
@@ -66,6 +66,7 @@ class CDVDVideoCodecFFmpeg : public CDVDVideoCodec
IHardwareDecoder * GetHardware() { return m_pHardware; };
void SetHardware(IHardwareDecoder* hardware)
{
+ SAFE_RELEASE(m_pHardware);
m_pHardware = hardware;
m_name += "-";
m_name += m_pHardware->Name();

0 comments on commit b0bcef1

Please sign in to comment.