From: Gildas Bazin Date: Mon, 17 May 2004 16:10:32 +0000 (+0000) Subject: * src/input/input_programs.c: if no program is specified by the user, don't add any... X-Git-Tag: 0.7.2~45 X-Git-Url: https://git.sesse.net/?a=commitdiff_plain;h=81333241d6421f53c968e0cd02ea4c1cb262505c;p=vlc * src/input/input_programs.c: if no program is specified by the user, don't add any to the list. --- diff --git a/src/input/input_programs.c b/src/input/input_programs.c index 5a73f72169..8c0e2a61b5 100644 --- a/src/input/input_programs.c +++ b/src/input/input_programs.c @@ -91,8 +91,11 @@ int input_InitStream( input_thread_t * p_input, size_t i_data_len ) var_Set( p_input, "intf-change", val ); /* Create a few object variables used for navigation in the interfaces */ - var_Create( p_input, "program", VLC_VAR_INTEGER | VLC_VAR_HASCHOICE - | VLC_VAR_DOINHERIT ); + var_Create( p_input, "program", VLC_VAR_INTEGER | VLC_VAR_HASCHOICE | + VLC_VAR_DOINHERIT ); + var_Get( p_input, "program", &val ); + if( val.i_int <= 0 ) + var_Change( p_input, "program", VLC_VAR_DELCHOICE, &val, NULL ); text.psz_string = _("Program"); var_Change( p_input, "program", VLC_VAR_SETTEXT, &text, NULL );