X-Git-Url: https://plomlompom.com/repos/foo.html?a=blobdiff_plain;f=src%2Fclient%2Fcommand_db.c;h=3837d2ab888bb6c8fdb0f86aad4f2964a9b9acb7;hb=0cc6c4ad7e0b01e2a89ced908f410eadf3f22b1f;hp=aed92c95beff5d5450c4b93653f2ac0e0c4304c5;hpb=6f98f0b029c3e84f1df0f2f3642f88e91b17cf33;p=plomrogue
diff --git a/src/client/command_db.c b/src/client/command_db.c
index aed92c9..3837d2a 100644
--- a/src/client/command_db.c
+++ b/src/client/command_db.c
@@ -7,7 +7,7 @@
#include /* free() */
#include /* memset(), strlen(), strcmp() */
#include "../common/err_try_fgets.h" /* reset_err_try_fgets_counter() */
-#include "../common/readwrite.h" /* try_fopen(),try_fclose(),textfile_sizes() */
+#include "../common/readwrite.h" /* try_fopen(),try_fclose(),textfile_width() */
#include "../common/rexit.h" /* exit_trouble() */
#include "../common/try_malloc.h" /* try_malloc() */
#include "misc.h" /* array_append() */
@@ -50,7 +50,7 @@ extern void init_command_db()
char * f_name = "init_command_db()";
char * context = "Failed reading command DB file. ";
FILE * file = try_fopen(world.path_commands, "r", f_name);
- uint32_t linemax = textfile_sizes(file, NULL);
+ uint32_t linemax = textfile_width(file);
char line[linemax + 1];
reset_err_try_fgets_counter();
uint8_t i = 0;