[vlc-devel] [PATCH 2/2] dshow: Use vlc_mta_holder
Hugo Beauzée-Luyssen
hugo at beauzee.fr
Mon Jun 12 17:12:11 CEST 2017
---
modules/access/dshow/dshow.cpp | 6 ++++++
1 file changed, 6 insertions(+)
diff --git a/modules/access/dshow/dshow.cpp b/modules/access/dshow/dshow.cpp
index ec8c8ec0cc..75d01b970c 100644
--- a/modules/access/dshow/dshow.cpp
+++ b/modules/access/dshow/dshow.cpp
@@ -52,6 +52,8 @@
#include "access.h"
#include "filter.h"
+#include "../src/win32/mta_holder.h"
+
#define INSTANCEDATA_OF_PROPERTY_PTR(x) ((PKSPROPERTY((x))) + 1)
#define INSTANCEDATA_OF_PROPERTY_SIZE(x) (sizeof((x)) - sizeof(KSPROPERTY))
@@ -658,6 +660,8 @@ static int CommonOpen( vlc_object_t *p_this, access_sys_t *p_sys,
if( p_sys->pp_streams.empty() ) return VLC_EGENERIC;
+ vlc_mta_acquire( p_this );
+
return VLC_SUCCESS;
}
@@ -822,6 +826,8 @@ static void CommonClose( vlc_object_t *p_this, access_sys_t *p_sys )
vlc_mutex_destroy( &p_sys->lock );
vlc_cond_destroy( &p_sys->wait );
+ vlc_mta_release( p_this );
+
free( p_sys );
}
--
2.11.0
More information about the vlc-devel
mailing list