Skip to content

Commit

Permalink
Also sync after rtc change
Browse files Browse the repository at this point in the history
  • Loading branch information
Spritetm committed Jun 26, 2024
1 parent 845577b commit cfdbb65
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions rtcram.c
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@
#include "emu.h"
#include "log.h"
#include "rtcram.h"
#include "emscripten_env.h"

// Debug logging (shared with the RTC clock portion)
#define RTC_LOG(msg_level, format_and_args...) \
Expand Down Expand Up @@ -41,6 +42,9 @@ void rtcram_write8(void *obj, unsigned int a, unsigned int val) {
} else {
RTC_LOG_WARNING("RTC: Failed to persist RTC RAM to %s\n", r->filename);
}
#ifdef __EMSCRIPTEN__
emscripten_syncfs();
#endif
}

void rtcram_write16(void *obj, unsigned int a, unsigned int val) {
Expand Down

0 comments on commit cfdbb65

Please sign in to comment.