[Mplayer-cvslog] CVS: main/Gui/mplayer/gtk fs.c,1.33,1.34

Zoltan Ponekker pontscho at mplayerhq.hu
Sat Sep 28 22:33:59 CEST 2002


Update of /cvsroot/mplayer/main/Gui/mplayer/gtk
In directory mail:/var/tmp.root/cvs-serv25824

Modified Files:
	fs.c 
Log Message:
fix filter handling bug

Index: fs.c
===================================================================
RCS file: /cvsroot/mplayer/main/Gui/mplayer/gtk/fs.c,v
retrieving revision 1.33
retrieving revision 1.34
diff -u -r1.33 -r1.34
--- fs.c	28 Sep 2002 20:09:13 -0000	1.33
+++ fs.c	28 Sep 2002 20:33:56 -0000	1.34
@@ -33,7 +33,7 @@
 gchar         * fsSelectedFile = NULL;
 gchar         * fsSelectedDirectory = NULL;
 unsigned char * fsThatDir = ".";
-gchar           fsFilter[256] = "*";
+gchar         * fsFilter = "*";
 
 int             fsPressed = 0;
 int             fsType    = 0;
@@ -173,7 +173,6 @@
   }
  globfree( &gg );
 
-//printf( "fsFiler: '%s'\n",fsFilter );
  if ( strchr( fsFilter,',' ) )
   {
    char tmp[8];
@@ -335,7 +334,7 @@
 
 void fs_fsFilterCombo_activate( GtkEditable * editable,gpointer user_data )
 {
- strcpy( fsFilter,gtk_entry_get_text( GTK_ENTRY( user_data ) ) );
+ fsFilter=gtk_entry_get_text( GTK_ENTRY( user_data ) );
  CheckDir( fsFNameList,get_current_dir_name() );
 }
 
@@ -351,27 +350,27 @@
    case fsVideoSelector:
           for( i=0;fsVideoFilterNames[i][0];i++ )
            if( !strcmp( str,fsVideoFilterNames[i][0] ) )
-            { strcpy( fsFilter,fsVideoFilterNames[i][1] ); break; }
+            { fsFilter=fsVideoFilterNames[i][1]; break; }
           break;
    case fsSubtitleSelector:
           for( i=0;fsSubtitleFilterNames[i][0];i++ )
            if( !strcmp( str,fsSubtitleFilterNames[i][0] ) )
-            { strcpy( fsFilter,fsSubtitleFilterNames[i][1] ); break; }
+            { fsFilter=fsSubtitleFilterNames[i][1]; break; }
           break;
    case fsOtherSelector:
           for( i=0;fsOtherFilterNames[i][0];i++ )
            if( !strcmp( str,fsOtherFilterNames[i][0] ) )
-            { strcpy( fsFilter,fsOtherFilterNames[i][1] ); break; }
+            { fsFilter=fsOtherFilterNames[i][1]; break; }
           break;
    case fsAudioSelector:
           for( i=0;fsAudioFileNames[i][0];i++ )
            if( !strcmp( str,fsAudioFileNames[i][0] ) )
-            { strcpy( fsFilter,fsAudioFileNames[i][1] ); break; }
+            { fsFilter=fsAudioFileNames[i][1]; break; }
 	  break;
    case fsFontSelector:
           for( i=0;fsFontFileNames[i][0];i++ )
 	    if( !strcmp( str,fsFontFileNames[i][0] ) )
-	     { strcpy( fsFilter,fsFontFileNames[i][1] ); break; }
+	     { fsFilter,fsFontFileNames[i][1]; break; }
 	  break;
    default: return;
   }




More information about the MPlayer-cvslog mailing list