From: Antoine Cellerier Date: Fri, 14 Apr 2006 16:47:23 +0000 (+0000) Subject: Prevent some segfaults when using hotkeys with no vout X-Git-Tag: 0.9.0-test0~11503 X-Git-Url: https://git.sesse.net/?a=commitdiff_plain;h=c1f5a1a657fe2f99f86568bda962d562590f4b58;p=vlc Prevent some segfaults when using hotkeys with no vout --- diff --git a/modules/control/hotkeys.c b/modules/control/hotkeys.c index 2200c63241..6903197afc 100644 --- a/modules/control/hotkeys.c +++ b/modules/control/hotkeys.c @@ -511,7 +511,7 @@ static void Run( intf_thread_t *p_intf ) _("Subtitle track: %s"), list2.p_list->p_values[i].psz_string ); } - else if( i_action == ACTIONID_ASPECT_RATIO ) + else if( i_action == ACTIONID_ASPECT_RATIO && p_vout ) { vlc_value_t val={0}, val_list, text_list; var_Get( p_vout, "aspect-ratio", &val ); @@ -537,7 +537,7 @@ static void Run( intf_thread_t *p_intf ) } free( val.psz_string ); } - else if( i_action == ACTIONID_CROP ) + else if( i_action == ACTIONID_CROP && p_vout ) { vlc_value_t val={0}, val_list, text_list; var_Get( p_vout, "crop", &val ); @@ -563,7 +563,7 @@ static void Run( intf_thread_t *p_intf ) } free( val.psz_string ); } - else if( i_action == ACTIONID_DEINTERLACE ) + else if( i_action == ACTIONID_DEINTERLACE && p_vout ) { vlc_value_t val={0}, val_list, text_list; var_Get( p_vout, "deinterlace", &val );