]> git.xonotic.org Git - xonotic/gmqcc.git/blobdiff - opts.c
who let the cat out?
[xonotic/gmqcc.git] / opts.c
diff --git a/opts.c b/opts.c
index 3e7e2073b834539e1464b6dce0570d071be49a70..1d8fd73597d6f4ae0d2861347e6422f466bc9891 100644 (file)
--- a/opts.c
+++ b/opts.c
@@ -90,6 +90,8 @@ static void opts_setdefault(void) {
     opts_set(opts.warn,  WARN_UNINITIALIZED_CONSTANT,    true);
     opts_set(opts.warn,  WARN_DEPRECATED,                true);
     opts_set(opts.warn,  WARN_PARENTHESIS,               true);
+    opts_set(opts.warn,  WARN_CONST_OVERWRITE,           true);
+    opts_set(opts.warn,  WARN_DIRECTIVE_INMACRO,         true);
 
     /* flags */
     opts_set(opts.flags, ADJUST_VECTOR_FIELDS,           true);
@@ -211,7 +213,7 @@ static char *opts_ini_next(const char *s, char c) {
 }
 
 static size_t opts_ini_parse (
-    FILE   *filehandle,
+    fs_file_t *filehandle,
     char *(*loadhandle)(const char *, const char *, const char *),
     char **errorhandle
 ) {
@@ -228,7 +230,7 @@ static size_t opts_ini_parse (
     char *read_name;
     char *read_value;
 
-    while (fs_file_getline(&line, &linesize, filehandle) != EOF) {
+    while (fs_file_getline(&line, &linesize, filehandle) != FS_FILE_EOF) {
         parse_beg = line;
 
         /* handle BOM */
@@ -378,7 +380,7 @@ void opts_ini_init(const char *file) {
      */
     char       *error = NULL;
     size_t     line;
-    FILE       *ini;
+    fs_file_t  *ini;
 
     if (!file) {
         /* try ini */