.TH openreadclose 3 .SH NAME openreadclose \- read a whole file into a stralloc .SH SYNTAX .B #include extern int \fBopenreadclose\fP(const char *\fIfilename\fR, stralloc* \fIsa\fR,unsigned int \fIbufsize\fR); .SH DESCRIPTION openreadclose opens the file \fIfilename\fR for reading and reads the whole content into the stralloc \fIsa\fR. The file is read in chunks of \fIbufsize\fR bytes size. If everything worked fine, openreadclose returns 0. A not existing file is treated as an empty file. On error, openreadclose returns -1 and sets errno appropriately. .SH "SEE ALSO" open_read(3), readclose(3)