X-Git-Url: https://plomlompom.com/repos/?a=blobdiff_plain;f=src%2Fcommon%2Freadwrite.h;h=4aebdbc9b1d1fc3e94cad5b9898d51399da6b310;hb=a3c8dd9de99c7c77ad8218c3767abd4475c3dab6;hp=9c1358a693c10112648677b62d9bf7794b417a35;hpb=dd9d65ee727ac7e95801da0f8b5bae7009811802;p=plomrogue diff --git a/src/common/readwrite.h b/src/common/readwrite.h index 9c1358a..4aebdbc 100644 --- a/src/common/readwrite.h +++ b/src/common/readwrite.h @@ -22,7 +22,7 @@ extern void try_fputc(uint8_t c, FILE * file, char * f); /* Wrapper to calling fgetc() and fgets() from function "f". The return code is * returned unless ferror() indicates an error (i.e. to signify an end of file, - * fgetc() may return an EOF and fgets() a NULL. + * fgetc() may return an EOF and fgets() a NULL). */ extern int try_fgetc(FILE * file, char * f); extern char * try_fgets(char * line, int size, FILE * file, char * f); @@ -34,11 +34,8 @@ extern char * try_fgets(char * line, int size, FILE * file, char * f); extern void try_fclose_unlink_rename(FILE * file, char * p1, char * p2, char * f); -/* Return largest line length from "file" the largest line length (including - * newline chars) and write the number of newline chars in "file" to the memory - * pointed to by "n_lines_p" if it is not passed as NULL. - */ -extern uint32_t textfile_sizes(FILE * file, uint32_t * n_lines_p); +/* Return largest line length from "file" (including newline chars). */ +extern uint32_t textfile_width(FILE * file);