home · contact · privacy
Removed redundant "return".
[plomrogue] / src / server / init.c
index b63fbf96843dad69998e453fdf851b9a58db7ae0..c06619fc46cffc682480923d0bebd8140152fcbb 100644 (file)
@@ -7,7 +7,7 @@
 #include <string.h> /* atoi() */
 #include <time.h> /* time() */
 #include <unistd.h> /* optarg, getopt(), access(), unlink() */
-#include "../common/readwrite.h" /* try_fopen(), try_fclose(), textfile_sizes(),
+#include "../common/readwrite.h" /* try_fopen(), try_fclose(), textfile_width(),
                                   * try_fgets()
                                   */
 #include "../common/rexit.h" /* exit_err() */
@@ -53,7 +53,6 @@ extern void remake_world(uint32_t seed)
     world.log = NULL;  /* map_object_action.c's update_log() checks for this. */
     world.seed = seed;
     world.map_obj_count = 0;
-    world.score = 0;
     free(world.map.cells);
     free_map_objects(world.map_objs);
     world.last_update_turn = 0;
@@ -80,7 +79,7 @@ extern void run_game()
     if (!access(world.path_record, F_OK))
     {
         FILE * file = try_fopen(world.path_record, "r", f_name);
-        uint32_t linemax = textfile_sizes(file, NULL);
+        uint32_t linemax = textfile_width(file);
         char line[linemax + 1];
         while (   (!world.replay || (world.turn < world.replay))
                && NULL != try_fgets(line, linemax + 1, file, f_name))