Commit Graph

2 Commits

Author SHA1 Message Date
Darren Tucker 872517ddbb Defer setting bufsiz in getdelim.
Do not write to bufsiz until we are sure the malloc has succeeded,
in case any callers rely on it (which they shouldn't).  ok djm@
2018-07-06 13:32:02 +10:00
Darren Tucker 6301e6c787 Add implementation of getline.
Add getline for the benefit of platforms that don't have it.  Sourced
from NetBSD (OpenBSD's implementation is a little too chummy with the
internals of FILE).
2018-07-02 21:36:31 +10:00