This is an automated email from the ASF dual-hosted git repository.

morningman pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/incubator-doris.git


The following commit(s) were added to refs/heads/master by this push:
     new c6822f5  [Code refactor] Remove unnecessary if condition (#3459)
c6822f5 is described below

commit c6822f513a92affe8b1d78fd6b389bfa44ebc12e
Author: sduzh <zhuming9...@qq.com>
AuthorDate: Mon May 4 15:26:52 2020 +0800

    [Code refactor] Remove unnecessary if condition (#3459)
    
    if _opts.conditions is nullptr, the set cids would be empty.
---
 be/src/olap/rowset/segment_v2/segment_iterator.cpp | 5 +----
 1 file changed, 1 insertion(+), 4 deletions(-)

diff --git a/be/src/olap/rowset/segment_v2/segment_iterator.cpp 
b/be/src/olap/rowset/segment_v2/segment_iterator.cpp
index cbb4024..50e81d0 100644
--- a/be/src/olap/rowset/segment_v2/segment_iterator.cpp
+++ b/be/src/olap/rowset/segment_v2/segment_iterator.cpp
@@ -239,10 +239,7 @@ Status 
SegmentIterator::_get_row_ranges_from_conditions(RowRanges* condition_row
     for (auto& cid : cids) {
         // get row ranges by bf index of this column,
         RowRanges column_bf_row_ranges = RowRanges::create_single(num_rows());
-        CondColumn* column_cond = nullptr;
-        if (_opts.conditions != nullptr) {
-            column_cond = _opts.conditions->get_column(cid);
-        }
+        CondColumn* column_cond = _opts.conditions->get_column(cid);
         RETURN_IF_ERROR(
             _column_iterators[cid]->get_row_ranges_by_bloom_filter(
                 column_cond,


---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscr...@doris.apache.org
For additional commands, e-mail: commits-h...@doris.apache.org

Reply via email to