summaryrefslogtreecommitdiffhomepage
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/gameinfo.c6
-rw-r--r--src/os.h1
2 files changed, 4 insertions, 3 deletions
diff --git a/src/gameinfo.c b/src/gameinfo.c
index de5fafc..a5f1a42 100644
--- a/src/gameinfo.c
+++ b/src/gameinfo.c
@@ -54,7 +54,7 @@ static int storeargs(int argc, char *argv[]) {
return 0;
}
__attribute__((used, section(".init_array")))
-static void *pstoreargs = &storeargs;
+static void *pstoreargs = (void *)&storeargs;
#endif
// case insensitive substring match, expects s2 to be lowercase already!
@@ -333,8 +333,8 @@ bool gameinfo_init(void) {
}
os_char gameinfopath[PATH_MAX];
if (os_snprintf(gameinfopath, PATH_MAX, OS_LIT("%s/gameinfo.txt"),
- gamedir, modname) >= PATH_MAX) {
- con_warn("gameinfo: gameinfo.text path is too long!\n");
+ gamedir) >= PATH_MAX) {
+ con_warn("gameinfo: gameinfo.txt path is too long!\n");
return false;
}
diff --git a/src/os.h b/src/os.h
index d231e67..0b4d5e1 100644
--- a/src/os.h
+++ b/src/os.h
@@ -42,6 +42,7 @@
#else
#include <dlfcn.h>
#include <limits.h>
+#include <stdio.h>
#include <string.h>
#include <strings.h>
#include <sys/mman.h>