]> git.pond.sub.org Git - empserver/commitdiff
Make allocate_memory() return void
authorMarkus Armbruster <armbru@pond.sub.org>
Sat, 29 Oct 2011 18:19:06 +0000 (20:19 +0200)
committerMarkus Armbruster <armbru@pond.sub.org>
Thu, 29 Dec 2011 10:47:05 +0000 (11:47 +0100)
It can't fail since commit ba1a320c, v4.3.15.

src/util/fairland.c

index f885720b8d09f96731015dd027cba342b2a593f8..d2e2cc8963cf85d396c1d429ae051d7b8efe3a6f 100644 (file)
@@ -152,7 +152,7 @@ static const char *numletter =
 static void help(char *);
 static void usage(void);
 static void parse_args(int argc, char *argv[]);
-static int allocate_memory(void);
+static void allocate_memory(void);
 static void init(void);
 static int drift(void);
 static void grow_continents(void);
@@ -227,8 +227,7 @@ main(int argc, char *argv[])
        exit(1);
     empfile_fixup();
 
-    if (allocate_memory() == -1)
-       exit(-1);
+    allocate_memory();
     print_vars();
 
     do {
@@ -430,7 +429,7 @@ parse_args(int argc, char *argv[])
   VARIABLE INITIALIZATION
 ****************************************************************************/
 
-static int
+static void
 allocate_memory(void)
 {
     int i;
@@ -463,7 +462,6 @@ allocate_memory(void)
        sectc[i] = calloc(is * 2, sizeof(int));
     }
 
-    return 0;
 }
 
 static void