1
/* fio.h: File IO header file */
2
/* Copyright (c) 2000-2001 Fabien Tassin <fta@sofaraway.org> */
17
#define FIO_BUFFER 8192
23
/* initialize a FIO struct given an already openned file */
24
FIO* FIO_init(int fh);
26
void FIO_free(FIO *fio);
28
/* read a line in the given socket */
29
char *FIO_readline(FIO* fio);
31
/* write the buffer into the filehandle ('\r\n' added) */
32
int FIO_writeline(FIO *fio, char* buf);
34
/* write the buffer into the filehandle (no '\r\n' added) */
35
int FIO_write(FIO *fio, char* buf);
37
#define FIO_error(fio) ((fio)->status > 0)
38
#define FIO_toolong(fio) ((fio)->status == FIO_TOOLONG)