X-Git-Url: https://plomlompom.com/repos/?a=blobdiff_plain;f=src%2Fcommon%2Freadwrite.h;h=ce7b749bc251c9ebea8f6be257b230b74ca0cb35;hb=063eb0e64a0a2122c5581a668217290eb0b01f2b;hp=c5f0ccc2a5af72589685a5c867e45c01901daf11;hpb=28b8b4234e395c3fdc4800e5cfb3dcd70a15cadf;p=plomrogue diff --git a/src/common/readwrite.h b/src/common/readwrite.h index c5f0ccc..ce7b749 100644 --- a/src/common/readwrite.h +++ b/src/common/readwrite.h @@ -53,6 +53,14 @@ extern void detect_atomic_leftover(char * path); /* Return largest line length from "file" (including newline chars). */ extern uint32_t textfile_width(FILE * file); +/* Read "file" for load of non-zero bytes to put onto "queue" string. */ +extern uint8_t read_file_into_queue(FILE * file, char ** queue); + +/* Return message from "queue" (identified as \n-delimited string, with \n as + * \0 in the returned message; return nothing if no \n delimiter found). + */ +extern char * get_message_from_queue(char ** queue); + #endif