tmp++;
for( i = 0; sub_exts[i]; i++ )
- if( strcmp( sub_exts[i], tmp ) == 0 )
+ if( strcasecmp( sub_exts[i], tmp ) == 0 )
return 1;
}
return 0;
"autodetected subtitle: %s with priority %d",
psz_path, i_prio );
- if( utf8_stat( psz_path, &st ) && S_ISREG( st.st_mode ) )
+ if( !utf8_stat( psz_path, &st ) && S_ISREG( st.st_mode ) )
{
msg_Dbg( p_this,
"autodetected subtitle: %s with priority %d",
}
else
{
- msg_Dbg( p_this, "fopen failed" );
+ msg_Dbg( p_this, "stat failed" );
}
}
if( i_sub_count >= MAX_SUBTITLE_FILES ) break;