Commit 08223d48 authored by Rémi Denis-Courmont's avatar Rémi Denis-Courmont

Remove pf_run

parent ed41887c
......@@ -52,15 +52,12 @@ typedef struct intf_thread_t
VLC_COMMON_MEMBERS
struct intf_thread_t *p_next; /** LibVLC interfaces book keeping */
vlc_thread_t thread; /** LibVLC thread */
/* Thread properties and locks */
/* Specific interfaces */
intf_sys_t * p_sys; /** system interface */
/** Interface module */
module_t * p_module;
void ( *pf_run ) ( struct intf_thread_t * ); /** Run function */
/** Specific for dialogs providers */
void ( *pf_show_dialog ) ( struct intf_thread_t *, int, int,
......
......@@ -231,7 +231,6 @@ static int Open( vlc_object_t *p_this )
dbus_connection_flush( p_conn );
p_intf->pf_run = NULL;
p_intf->p_sys = p_sys;
p_sys->p_conn = p_conn;
p_sys->p_events = vlc_array_new();
......
......@@ -70,7 +70,5 @@ static int Open( vlc_object_t *p_this )
msg_Info( p_intf, "using the dummy interface module..." );
p_intf->pf_run = NULL;
return VLC_SUCCESS;
}
......@@ -123,7 +123,6 @@ static int Open( vlc_object_t *p_this )
return VLC_ENOMEM;
p_intf->p_sys = p_sys;
p_intf->pf_run = NULL;
p_sys->p_last_vout = NULL;
p_intf->p_sys->i_mousewheel_mode =
......
......@@ -97,8 +97,6 @@ static int Open( vlc_object_t *p_this )
if( p_sys == NULL )
return VLC_ENOMEM;
p_intf->pf_run = NULL;
p_sys->i_fd = lirc_init( "vlc", 1 );
if( p_sys->i_fd == -1 )
{
......
......@@ -93,7 +93,6 @@ error:
return VLC_EGENERIC;
}
p_intf->pf_run = NULL;
p_intf->p_sys = p_sys;
if( vlc_clone( &p_sys->thread, RunIntf, p_intf, VLC_THREAD_PRIORITY_LOW ) )
......
......@@ -127,7 +127,6 @@ static int Open(vlc_object_t *object)
return VLC_EGENERIC;
}
intf->pf_run = NULL;
intf->p_sys = sys = malloc(sizeof(*sys));
if (!sys) {
net_Close(fd);
......
......@@ -111,7 +111,6 @@ static int Activate( vlc_object_t *p_this )
if( unlikely(p_sys == NULL) )
return VLC_ENOMEM;
p_intf->pf_run = NULL;
p_intf->p_sys = p_sys;
if( vlc_clone( &p_sys->thread, Run, p_intf, VLC_THREAD_PRIORITY_LOW ) )
......
......@@ -330,8 +330,6 @@ static int Activate( vlc_object_t *p_this )
/* Non-buffered stdout */
setvbuf( stdout, (char *)NULL, _IOLBF, 0 );
p_intf->pf_run = NULL;
#ifdef WIN32
p_intf->p_sys->b_quiet = var_InheritBool( p_intf, "rc-quiet" );
if( !p_intf->p_sys->b_quiet )
......
......@@ -1827,7 +1827,6 @@ static int Open(vlc_object_t *p_this)
if (vlc_clone(&sys->thread, Run, intf, VLC_THREAD_PRIORITY_LOW))
abort(); /* TODO */
intf->pf_run = NULL;
return VLC_SUCCESS;
}
......
......@@ -430,8 +430,6 @@ static int Open(vlc_object_t *p_this)
var_AddCallback(pl_Get(p_intf), "activity", ItemChange, p_intf);
p_intf->pf_run = NULL;
return VLC_SUCCESS;
}
......
......@@ -127,15 +127,6 @@ int intf_Create( vlc_object_t *p_this, const char *chain )
goto error;
}
/* Run the interface in a separate thread */
if( p_intf->pf_run
&& vlc_clone( &p_intf->thread,
RunInterface, p_intf, VLC_THREAD_PRIORITY_LOW ) )
{
msg_Err( p_intf, "cannot spawn interface thread" );
goto error;
}
vlc_mutex_lock( &lock );
p_intf->p_next = libvlc_priv( p_libvlc )->p_intf;
libvlc_priv( p_libvlc )->p_intf = p_intf;
......@@ -176,11 +167,6 @@ void intf_DestroyAll( libvlc_int_t *p_libvlc )
{
intf_thread_t *p_next = p_intf->p_next;
if( p_intf->pf_run )
{
vlc_cancel( p_intf->thread );
vlc_join( p_intf->thread, NULL );
}
module_unneed( p_intf, p_intf->p_module );
config_ChainDestroy( p_intf->p_cfg );
vlc_object_release( p_intf );
......@@ -191,19 +177,6 @@ void intf_DestroyAll( libvlc_int_t *p_libvlc )
/* Following functions are local */
/**
* RunInterface: setups necessary data and give control to the interface
*
* @param p_this: interface object
*/
static void* RunInterface( void *p_this )
{
intf_thread_t *p_intf = p_this;
p_intf->pf_run( p_intf );
return NULL;
}
static int AddIntfCallback( vlc_object_t *p_this, char const *psz_cmd,
vlc_value_t oldval, vlc_value_t newval, void *p_data )
{
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment