]> git.sesse.net Git - vlc/commitdiff
Fall back to plain C with default C character encoding when UTF8 fails.
authorDerk-Jan Hartman <hartman@videolan.org>
Wed, 31 Mar 2004 00:24:22 +0000 (00:24 +0000)
committerDerk-Jan Hartman <hartman@videolan.org>
Wed, 31 Mar 2004 00:24:22 +0000 (00:24 +0000)
now you can see at least something with those SAP announces with Latin char encoding.

modules/gui/macosx/playlist.m

index 0edcae9896f4c288f0298cc71838ea95afc2cd0f..711f7e14c8b83e6ec4fe15fb364f980dd61cf07b 100644 (file)
@@ -666,6 +666,9 @@ belongs to an Apple hidden private API, and then can "disapear" at any time*/
         vlc_mutex_lock( &p_playlist->object_lock );
         o_value = [NSString stringWithUTF8String: 
             p_playlist->pp_items[i_row]->psz_name];
+        if( o_value == NULL )
+            o_value = [NSString stringWithCString: 
+                p_playlist->pp_items[i_row]->psz_name];
         vlc_mutex_unlock( &p_playlist->object_lock );
     }
     else if( [[o_tc identifier] isEqualToString:@"2"] )
@@ -673,6 +676,9 @@ belongs to an Apple hidden private API, and then can "disapear" at any time*/
         vlc_mutex_lock( &p_playlist->object_lock );
         o_value = [NSString stringWithUTF8String: 
             playlist_GetInfo(p_playlist, i_row ,_("General"),_("Author") )];
+        if( o_value == NULL )
+            o_value = [NSString stringWithCString: 
+                playlist_GetInfo(p_playlist, i_row ,_("General"),_("Author") )];
         vlc_mutex_unlock( &p_playlist->object_lock );
     }
     else if( [[o_tc identifier] isEqualToString:@"3"] )