filename | src/dreamcast.c |
changeset | 422:61a0598e07ff |
prev | 372:86aa060ddcec |
next | 450:207461e79f21 |
author | nkeynes |
date | Thu Oct 11 08:22:03 2007 +0000 (16 years ago) |
permissions | -rw-r--r-- |
last change | Add speed meter to main window Add sunken border around video area Add debugger menu item Move logging out to util.c |
file | annotate | diff | log | raw |
1.1 --- a/src/dreamcast.c Sat Sep 08 04:38:38 2007 +00001.2 +++ b/src/dreamcast.c Thu Oct 11 08:22:03 2007 +00001.3 @@ -1,5 +1,5 @@1.4 /**1.5 - * $Id: dreamcast.c,v 1.22 2007-09-08 04:38:38 nkeynes Exp $1.6 + * $Id: dreamcast.c,v 1.23 2007-10-06 08:59:42 nkeynes Exp $1.7 * Central switchboard for the system. This pulls all the individual modules1.8 * together into some kind of coherent structure. This is also where you'd1.9 * add Naomi support, if I ever get a board to play with...1.10 @@ -36,7 +36,7 @@1.11 #define STATE_STOPPED 31.12 static volatile int dreamcast_state = STATE_UNINIT;1.13 static uint32_t timeslice_length = DEFAULT_TIMESLICE_LENGTH;1.14 -static char *dreamcast_config = "DEFAULT";1.15 +const char *dreamcast_config = "DEFAULT";1.17 #define MAX_MODULES 321.18 static int num_modules = 0;1.19 @@ -87,7 +87,7 @@1.21 void dreamcast_save_flash()1.22 {1.23 - char *file = dreamcast_get_config_value(CONFIG_FLASH_PATH);1.24 + const char *file = dreamcast_get_config_value(CONFIG_FLASH_PATH);1.25 mem_save_block( file, 0x00200000, 0x00020000 );1.26 }1.28 @@ -199,7 +199,6 @@1.29 void dreamcast_shutdown()1.30 {1.31 dreamcast_stop();1.32 - sh4_stop();1.33 dreamcast_save_flash();1.34 }1.36 @@ -272,7 +271,7 @@1.37 gboolean dreamcast_load_config_stream( FILE *f )1.38 {1.40 - char buf[512], *p;1.41 + char buf[512];1.42 int maple_device = -1, maple_subdevice = -1;1.43 struct dreamcast_config_group devgroup;1.44 struct dreamcast_config_group *group = NULL;1.45 @@ -365,6 +364,7 @@1.46 }1.47 result = dreamcast_save_config_stream(f);1.48 fclose(f);1.49 + return TRUE;1.50 }1.52 gboolean dreamcast_save_config_stream( FILE *f )1.53 @@ -416,7 +416,7 @@1.54 int dreamcast_load_state( const gchar *filename )1.55 {1.56 int i,j;1.57 - uint32_t count, len;1.58 + uint32_t len;1.59 int have_read[MAX_MODULES];1.60 char tmp[64];1.61 struct save_state_header header;1.62 @@ -485,6 +485,7 @@1.63 }1.64 fclose(f);1.65 INFO( "Save state read from %s", filename );1.66 + return 0;1.67 }1.69 int dreamcast_save_state( const gchar *filename )1.70 @@ -514,5 +515,6 @@1.71 }1.72 fclose( f );1.73 INFO( "Save state written to %s", filename );1.74 + return 0;1.75 }
.