1.1 --- a/src/dreamcast.c Mon Feb 15 17:27:14 2010 +1000
1.2 +++ b/src/dreamcast.c Tue Jul 13 16:26:49 2010 +1000
1.7 -int dreamcast_load_state( const gchar *filename )
1.8 +gboolean dreamcast_load_state( const gchar *filename )
1.12 @@ -456,13 +456,13 @@
1.13 int have_read[MAX_MODULES];
1.15 FILE *f = fopen( filename, "r" );
1.16 - if( f == NULL ) return errno;
1.17 + if( f == NULL ) return FALSE;
1.19 module_count = dreamcast_read_save_state_header(f, error, sizeof(error));
1.20 if( module_count <= 0 ) {
1.27 for( i=0; i<MAX_MODULES; i++ ) {
1.29 if( strncmp(chunk.marker, "BLCK", 4) != 0 ) {
1.30 ERROR( "%s save state is corrupted (missing block header %d)", APP_NAME, i );
1.36 /* Find the matching module by name */
1.37 @@ -485,11 +485,11 @@
1.38 if( modules[j]->load == NULL ) {
1.39 ERROR( "%s save state is corrupted (no loader for %s)", APP_NAME, modules[j]->name );
1.43 } else if( modules[j]->load(f) != 0 ) {
1.44 ERROR( "%s save state is corrupted (%s failed)", APP_NAME, modules[j]->name );
1.52 if( j == num_modules ) {
1.54 ERROR( "%s save state contains unrecognized section", APP_NAME );
1.63 INFO( "Save state read from %s", filename );
1.68 int dreamcast_save_state( const gchar *filename )