Your getline is better than mine

R

Richard Harter

I have done an implementation of the file reading routine. The
"man page" is at http://home.tiac.net/~cri/2007/gflspec.html.
It contains links to a directory containing two source files
called getfline.c and getfline.h. The directory URL is
http://home.tiac.net/~cri_a/source_code/getfline/.

The code has been run through a test suite, but the suite was not
so extensive that I will guarantee that it is ironclad.
Corrections and suggestions are always welcome.

The routine does not check for an attempt to read the same file
at the same time from two different places. Presumably this
should be a catchable error. Incidentally I can't tell from the
standard what happens if you attempt to open a file that already
is open. (I'm looking at 7.9.5.3 and 7.9.5.4 from Plauger's "The
Standard C Library".) It's not clear to me how this should be
handled.

The license is a BSD license with an extra clause requiring that
modified versions be labeled as modified versions.


Richard Harter, (e-mail address removed)
http://home.tiac.net/~cri, http://www.varinoma.com
In the fields of Hell where the grass grows high
Are the graves of dreams allowed to die
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,744
Messages
2,569,482
Members
44,901
Latest member
Noble71S45

Latest Threads

Top