Skip to content

Commit

Permalink
Fix file offset being zero (#166)
Browse files Browse the repository at this point in the history
  • Loading branch information
rui-mo authored and zhejiangxiaomai committed Mar 31, 2023
1 parent 799c054 commit 46521a0
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion velox/dwio/parquet/reader/ParquetReader.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -551,7 +551,11 @@ void ParquetRowReader::filterRowGroups() {
auto fileOffset = rowGroups_[i].__isset.file_offset
? rowGroups_[i].file_offset
: rowGroups_[i].columns[0].file_offset;
VELOX_CHECK_GT(fileOffset, 0);
VELOX_CHECK_GE(fileOffset, 0);
if (fileOffset == 0) {
rowGroupIds_.push_back(i);
continue;
}
auto rowGroupInRange =
(fileOffset >= options_.getOffset() &&
fileOffset < options_.getLimit());
Expand Down

0 comments on commit 46521a0

Please sign in to comment.