Rename some autosve functions

This commit is contained in:
twinaphex 2016-05-09 08:17:35 +02:00
parent 5f3f578311
commit d57574a2ca
5 changed files with 18 additions and 18 deletions

View File

@ -186,11 +186,11 @@ static void autosave_free(autosave_t *handle)
}
/**
* lock_autosave:
* autosave_lock:
*
* Lock autosave.
**/
void lock_autosave(void)
void autosave_lock(void)
{
unsigned i;
@ -202,11 +202,11 @@ void lock_autosave(void)
}
/**
* unlock_autosave:
* autosave_unlock:
*
* Unlocks autosave.
**/
void unlock_autosave(void)
void autosave_unlock(void)
{
unsigned i;
@ -217,7 +217,7 @@ void unlock_autosave(void)
}
}
void autosave_event_init(void)
void autosave_init(void)
{
unsigned i;
autosave_t **list = NULL;
@ -258,7 +258,7 @@ void autosave_event_init(void)
}
}
void autosave_event_deinit(void)
void autosave_deinit(void)
{
unsigned i;

View File

@ -26,22 +26,22 @@ extern "C" {
typedef struct autosave autosave_t;
/**
* lock_autosave:
* autosave_lock:
*
* Lock autosave.
**/
void lock_autosave(void);
void autosave_lock(void);
/**
* unlock_autosave:
* autosave_unlock:
*
* Unlocks autosave.
**/
void unlock_autosave(void);
void autosave_unlock(void);
void autosave_event_init(void);
void autosave_init(void);
void autosave_event_deinit(void);
void autosave_deinit(void);
#ifdef __cplusplus
}

View File

@ -1197,14 +1197,14 @@ bool event_cmd_ctl(enum event_command cmd, void *data)
global_t *global = global_get_ptr();
if (!global->sram.use)
return false;
autosave_event_deinit();
autosave_deinit();
}
#endif
break;
case EVENT_CMD_AUTOSAVE_INIT:
event_cmd_ctl(EVENT_CMD_AUTOSAVE_DEINIT, NULL);
#ifdef HAVE_THREADS
autosave_event_init();
autosave_init();
#endif
break;
case EVENT_CMD_AUTOSAVE_STATE:

View File

@ -88,11 +88,11 @@ static void netplay_net_post_frame(netplay_t *netplay)
core_serialize(&serial_info);
#if defined(HAVE_THREADS)
lock_autosave();
autosave_lock();
#endif
core_run();
#if defined(HAVE_THREADS)
unlock_autosave();
autosave_unlock();
#endif
netplay->tmp_ptr = NEXT_PTR(netplay->tmp_ptr);
netplay->tmp_frame_count++;

View File

@ -1452,7 +1452,7 @@ int runloop_iterate(unsigned *sleep_ms)
}
#if defined(HAVE_THREADS)
lock_autosave();
autosave_lock();
#endif
#ifdef HAVE_NETPLAY
@ -1503,7 +1503,7 @@ int runloop_iterate(unsigned *sleep_ms)
#endif
#if defined(HAVE_THREADS)
unlock_autosave();
autosave_unlock();
#endif
if (!settings->fastforward_ratio)