return NULL;
priv = libvlc_priv (p_libvlc);
- priv->p_playlist = NULL;
+ priv->playlist = NULL;
priv->p_dialog_provider = NULL;
priv->p_vlm = NULL;
}
if( asprintf( &psz_temp, "%s,none", psz_module ) != -1)
{
- intf_Create( p_libvlc, psz_temp );
+ libvlc_InternalAddIntf( p_libvlc, psz_temp );
free( psz_temp );
}
}
{
char *logmode = var_CreateGetNonEmptyString( p_libvlc, "logmode" );
var_SetString( p_libvlc, "logmode", "syslog" );
- intf_Create( p_libvlc, "logger,none" );
+ libvlc_InternalAddIntf( p_libvlc, "logger,none" );
if( logmode )
{
else
#endif
if( var_InheritBool( p_libvlc, "file-logging" ) )
- intf_Create( p_libvlc, "logger,none" );
+ libvlc_InternalAddIntf( p_libvlc, "logger,none" );
if( var_InheritBool( p_libvlc, "network-synchronisation") )
- {
- intf_Create( p_libvlc, "netsync,none" );
- }
+ libvlc_InternalAddIntf( p_libvlc, "netsync,none" );
#ifdef __APPLE__
var_Create( p_libvlc, "drawable-view-top", VLC_VAR_INTEGER );
psz_val = var_InheritString( p_libvlc, "open" );
if ( psz_val != NULL )
{
- playlist_AddExt( pl_Get(p_libvlc), psz_val, NULL, PLAYLIST_INSERT, 0,
- -1, 0, NULL, 0, true, pl_Unlocked );
+ intf_InsertItem( p_libvlc, psz_val, 0, NULL, 0 );
free( psz_val );
}
}
#endif
- /* Free playlist now, all threads are gone */
- playlist_t *p_playlist = libvlc_priv (p_libvlc)->p_playlist;
- if( p_playlist != NULL )
- playlist_Destroy( p_playlist );
-
#if !defined( _WIN32 ) && !defined( __OS2__ )
char *pidfile = var_InheritString( p_libvlc, "pidfile" );
if( pidfile != NULL )
vlc_object_release( p_libvlc );
}
-/**
- * Add an interface plugin and run it
- */
-int libvlc_InternalAddIntf( libvlc_int_t *p_libvlc, const char *name )
-{
- int ret;
-
- if( !p_libvlc )
- return VLC_EGENERIC;
-
- if( name != NULL )
- ret = intf_Create( p_libvlc, name );
- else
- { /* Default interface */
- char *intf = var_InheritString( p_libvlc, "intf" );
- if( intf == NULL ) /* "intf" has not been set */
- {
- char *pidfile = var_InheritString( p_libvlc, "pidfile" );
- if( pidfile != NULL )
- free( pidfile );
- else
- msg_Info( p_libvlc, "%s",
- _("Running vlc with the default interface. "
- "Use 'cvlc' to use vlc without interface.") );
- }
- ret = intf_Create( p_libvlc, intf );
- name = "default";
- }
- if( ret )
- msg_Err( p_libvlc, "interface \"%s\" initialization failed", name );
- return ret;
-}
-
/*****************************************************************************
* GetFilenames: parse command line options which are not flags
*****************************************************************************
continue;
}
- playlist_AddExt( pl_Get( p_vlc ), (mrl != NULL) ? mrl : args[n], NULL,
- PLAYLIST_INSERT, 0, -1, i_options,
+ intf_InsertItem( p_vlc, (mrl != NULL) ? mrl : args[n], i_options,
( i_options ? &args[n + 1] : NULL ),
- VLC_INPUT_OPTION_TRUSTED, true, pl_Unlocked );
+ VLC_INPUT_OPTION_TRUSTED );
free( mrl );
}
}