static struct
{
- char *psz_name;
- char *psz_option;
+ const char *psz_name;
+ const char *psz_option;
} dvb_options[] =
{
while( psz_parse )
{
- char *psz_option = 0;
+ const char *psz_option = 0;
char *psz_end = strchr( psz_parse, ':' );
if( psz_end ) { *psz_end = 0; psz_end++; }
if( psz_option && pppsz_options && pi_options )
{
- psz_option = strdup( psz_option );
- INSERT_ELEM( *pppsz_options, (*pi_options), (*pi_options),
- psz_option );
+ char *psz_dup = strdup( psz_option );
+ if (psz_dup != NULL)
+ INSERT_ELEM( *pppsz_options, (*pi_options), (*pi_options),
+ psz_dup );
}
psz_parse = psz_end;