Skip to content
Closed
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 3 additions & 0 deletions src/fread.c
Original file line number Diff line number Diff line change
Expand Up @@ -247,6 +247,9 @@ static inline void skip_white(const char **pch) {
*/
static inline bool eol(const char **pch) {
const char *ch = *pch;
if (*ch == '#') {
while (*ch != '\r' && *ch != '\n') ch++;
}
// we call eol() when we expect to be on an eol(), so optimize as if we are on an eol
while (*ch=='\r') ch++; // commonly happens once on Windows for type 2
if (*ch=='\n') {
Expand Down