summaryrefslogtreecommitdiff
path: root/libretro/libretro.c
diff options
context:
space:
mode:
Diffstat (limited to 'libretro/libretro.c')
-rw-r--r--libretro/libretro.c8
1 files changed, 7 insertions, 1 deletions
diff --git a/libretro/libretro.c b/libretro/libretro.c
index 2f50909..0321bf9 100644
--- a/libretro/libretro.c
+++ b/libretro/libretro.c
@@ -100,7 +100,13 @@ memstream_t *s_stream;
int s_open(const char *fname, const char *mode)
{
- s_stream = memstream_open(0);
+ unsigned writing = 0;
+
+ if (mode)
+ if (strcmp(mode, "wb") == 0)
+ writing = 1;
+
+ s_stream = memstream_open(writing);
return TRUE;
}