/*****************************************************************************
* jack.c: JACK audio input module
*****************************************************************************
- * Copyright (C) 2007 the VideoLAN team
+ * Copyright (C) 2007-2008 the VideoLAN team
* Copyright (C) 2007 Société des arts technologiques
* Copyright (C) 2007 Savoir-faire Linux
*
}
/* find some specifics ports if user entered a regexp */
- if( p_sys->psz_ports)
+ if( p_sys->psz_ports )
{
Port_finder( p_demux );
if( p_sys->i_channels == 0 )
p_vcdplayer = malloc( sizeof(vcdplayer_t) );
if( p_vcdplayer == NULL )
- {
- LOG_ERR ("out of memory" );
return VLC_ENOMEM;
- }
p_vcdplayer->i_debug = config_GetInt( p_this, MODULE_STRING "-debug" );
p_access->p_sys = (access_sys_t *) p_vcdplayer;
dbg_print( INPUT_DBG_EVENT, "GET TITLE: i_titles %d",
p_vcdplayer->i_titles );
- if( psz_mrl == NULL ) {
- msg_Warn( p_access, "out of memory" );
- } else {
+ if( psz_mrl )
+ {
snprintf(psz_mrl, psz_mrl_max, "%s%s",
VCD_MRL_PREFIX, p_vcdplayer->psz_source);
VCDMetaInfo( p_access, psz_mrl );
p_sys->p_thread =
vlc_object_create( p_access, sizeof( rtmp_control_thread_t ) );
if( !p_sys->p_thread )
- {
- msg_Err( p_access, "out of memory" );
return VLC_ENOMEM;
- }
vlc_object_attach( p_sys->p_thread, p_access );
/* Parse URI - remove spaces */
{
psz_comment = strdup( p_dec->p_sys->kc.user_comments[i] );
if( !psz_comment )
- {
- msg_Warn( p_dec, "out of memory" );
break;
- }
psz_name = psz_comment;
psz_value = strchr( psz_comment, '=' );
if( psz_value )
{
psz_comment = strdup( p_dec->p_sys->tc.user_comments[i] );
if( !psz_comment )
- {
- msg_Warn( p_dec, "out of memory" );
break;
- }
psz_name = psz_comment;
psz_value = strchr( psz_comment, '=' );
if( psz_value )
#endif
if( !( p_box->data.p_cmov = malloc( sizeof( MP4_Box_data_cmov_t ) ) ) )
- {
- msg_Err( p_stream, "out of memory" );
return 0;
- }
memset( p_box->data.p_cmov, 0, sizeof( MP4_Box_data_cmov_t ) );
if( !p_box->p_father ||
aout_instance_t * p_aout = (aout_instance_t*) p_this;
p_aout->output.p_sys = (aout_sys_t*) malloc( sizeof( aout_sys_t ) );
if( p_aout->output.p_sys == NULL )
- {
- msg_Err( p_aout, "out of memory" );
return -1;
- }
aout_sys_t * p_sys = p_aout->output.p_sys;
aout_VolumeSoftInit( p_aout );
/* Allocate instance and initialize some members */
p_intf->p_sys = (intf_sys_t*) malloc( sizeof( intf_sys_t ) );
if( !p_intf->p_sys )
- {
- msg_Err( p_intf, "out of memory" );
return VLC_EGENERIC;
- }
p_intf->pf_run = Run;
/* Allocate structure */
p_vout->p_sys = (vout_sys_t*) malloc( sizeof( vout_sys_t ) );
if( p_vout->p_sys == NULL )
- {
- msg_Err( p_vout, "out of memory" );
- return( 1 );
- }
+ return 1;
p_vout->p_sys->i_width = p_vout->render.i_width;
p_vout->p_sys->i_height = p_vout->render.i_height;
p_vout->p_sys->source_chroma = p_vout->render.i_chroma;
p_vout->p_sys = malloc( sizeof( vout_sys_t ) );
if( p_vout->p_sys == NULL )
- {
- msg_Err( p_vout, "out of memory" );
return( 1 );
- }
memset( p_vout->p_sys, 0, sizeof( vout_sys_t ) );
p_vout->p_sys = malloc( sizeof( vout_sys_t ) );
if( p_vout->p_sys == NULL )
- {
- msg_Err( p_vout, "out of memory" );
return( 1 );
- }
memset( p_vout->p_sys, 0, sizeof( vout_sys_t ) );
/* Allocate instance and initialize some members */
p_intf->p_sys = malloc( sizeof( intf_sys_t ) );
if( p_intf->p_sys == NULL )
- {
- msg_Err( p_intf, "out of memory" );
return VLC_ENOMEM;
- }
#ifdef NEED_GTK2_MAIN
msg_Dbg( p_intf, "Using gui-helper" );
/* allocate structure */
p_aout->output.p_sys = malloc( sizeof( aout_sys_t ) );
if( p_aout->output.p_sys == NULL )
- {
- msg_Err( p_aout, "out of memory" );
return -1;
- }
/* open audio device */
if( ( i_ret = snd_pcm_open_preferred( &p_aout->output.p_sys->p_pcm_handle,
/* allocate structure */
p_vout->p_sys = malloc( sizeof( vout_sys_t ) );
if( p_vout->p_sys == NULL )
- {
- msg_Err( p_vout, "out of memory" );
return( 1 );
- }
memset( p_vout->p_sys, 0, sizeof( vout_sys_t ) );
/* allocate buffer for event */
i_buflen = sizeof( PhEvent_t ) * 4;
if( ( p_event = malloc( i_buflen ) ) == NULL )
- {
- msg_Err( p_vout, "out of memory" );
return( 1 );
- }
/* event loop */
do
{
i_buflen = PhGetMsgSize( p_event );
if( ( p_event = realloc( p_event, i_buflen ) ) == NULL )
- {
- msg_Err( p_vout, "out of memory" );
return( 1 );
- }
}
else if( i_ev == Ph_EVENT_MSG )
{
// Allocate instance and initialize some members
p_intf->p_sys = (intf_sys_t *)malloc( sizeof( intf_sys_t ) );
if( p_intf->p_sys == NULL )
- {
- msg_Err( p_intf, "out of memory" );
- return VLC_EGENERIC;
- }
+ return VLC_ENOMEM;
// Suscribe to messages bank
p_intf->p_sys->p_sub = msg_Subscribe( p_intf );
sizeof(vout_thread_t *) );
if( p_vout->p_sys->pp_vout == NULL )
{
- msg_Err( p_vout, "out of memory" );
free( p_vout->p_sys );
return VLC_ENOMEM;
}