This is the mail archive of the ecos-discuss@sources.redhat.com mailing list for the eCos project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

FILESYSTEM QUESTION: reading all of the data in a file.


the POSIX read command: extern ssize_t read(int fd, void *buf, size_t nbyte);

I wish to read all the bytes in a jffs2 file, then use the size returned in a "cyg_io_write()" command to a serial interface modem, to send this data to the TX_FIFO.

Is there a method of reading all the bytes in a file without keeping a separately record of the number of bytes written to the file? or, is there a function that returns the number of bytes of data in a file? if so, what is the POSIX command?

Thank you

Dave Rentoul
Elands Communications Ltd




-- Before posting, please read the FAQ: http://ecos.sourceware.org/fom/ecos and search the list archive: http://ecos.sourceware.org/ml/ecos-discuss


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]