8b907136 | 13-Oct-2022 |
Baptiste Daroussin <bapt@FreeBSD.org> |
sort: unify the code to read from FILE *
Previously the code to read from a local file or stdin was sperarated After the change to remove the home made line reader used for stdin (replaced by getdel
sort: unify the code to read from FILE *
Previously the code to read from a local file or stdin was sperarated After the change to remove the home made line reader used for stdin (replaced by getdelim) it apprears that the rest of the code which is used to read from any FILE * but stdin can benefit from the exact same change.
show more ...
|
b58094c0 | 12-Oct-2022 |
Baptiste Daroussin <bapt@FreeBSD.org> |
sort: replace home made line reader by getdelim(3)
The previous code had bug when reading lines with an unexpected encoding, returning without the full line being captured. This result in sort compl
sort: replace home made line reader by getdelim(3)
The previous code had bug when reading lines with an unexpected encoding, returning without the full line being captured. This result in sort complaining with "sort: Illegal byte sequence"
Using getdelim(3) instead of the home made code, fixes the situation.
PR: 241679 Reported by: Ronald F. Guilmette <rfg-freebsd@tristatelogic.com> MFC After: 1 week Reviewed by: markj, imp Differential Revision: https://reviews.freebsd.org/D36948
show more ...
|