Skip to content

Commit 3278c79

Browse files
Set char_count to 0 when word_deletions is 0
This looks like the most sensible value as the number of words that is deleted is 0 therefore the char_count of characters to be skipped is also 0.
1 parent 0f793ef commit 3278c79

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

pandas/_libs/src/parser/tokenizer.c

+1-1
Original file line numberDiff line numberDiff line change
@@ -1193,7 +1193,7 @@ int parser_consume_rows(parser_t *self, size_t nrows) {
11931193
char_count = (self->word_starts[word_deletions - 1] +
11941194
strlen(self->words[word_deletions - 1]) + 1);
11951195
} else {
1196-
char_count = self->stream_len;
1196+
char_count = 0;
11971197
}
11981198

11991199
TRACE(("parser_consume_rows: Deleting %d words, %d chars\n", word_deletions,

0 commit comments

Comments
 (0)