diff options
author | Jaakko Keränen <jaakko.keranen@iki.fi> | 2021-11-02 16:49:56 +0200 |
---|---|---|
committer | Jaakko Keränen <jaakko.keranen@iki.fi> | 2021-11-02 16:49:56 +0200 |
commit | 0168064f1f711d298da7b094cd3ab8db6daddee4 (patch) | |
tree | 77a328957cc0bf75e1a55e10456143692ca801bf /src/gopher.c | |
parent | 26b1a9dd7434c2b81ee967e1958af65b47af3a5c (diff) |
Gopher: Allow either LF or CRLF line endings
IssueID #377
Diffstat (limited to 'src/gopher.c')
-rw-r--r-- | src/gopher.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/gopher.c b/src/gopher.c index ac5fe560..008a7743 100644 --- a/src/gopher.c +++ b/src/gopher.c | |||
@@ -103,10 +103,10 @@ static iBool convertSource_Gopher_(iGopher *d) { | |||
103 | for (;;) { | 103 | for (;;) { |
104 | /* Find the end of the line. */ | 104 | /* Find the end of the line. */ |
105 | iRangecc line = { body.start, body.start }; | 105 | iRangecc line = { body.start, body.start }; |
106 | while (line.end < body.end - 1 && !isCRLFLineTerminator_(line.end)) { | 106 | while (line.end < body.end - 1 && !isLineTerminator_(line.end)) { |
107 | line.end++; | 107 | line.end++; |
108 | } | 108 | } |
109 | if (line.end >= body.end - 1 || !isCRLFLineTerminator_(line.end)) { | 109 | if (line.end >= body.end - 1 || !isLineTerminator_(line.end)) { |
110 | /* Not a complete line. More may be coming later. */ | 110 | /* Not a complete line. More may be coming later. */ |
111 | break; | 111 | break; |
112 | } | 112 | } |