You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@doris.apache.org by GitBox <gi...@apache.org> on 2022/06/10 02:38:18 UTC

[GitHub] [incubator-doris] BiteTheDDDDt commented on a diff in pull request #10047: [Bug] [Storage] DCHECK fail on in_list_pred

BiteTheDDDDt commented on code in PR #10047:
URL: https://github.com/apache/incubator-doris/pull/10047#discussion_r894106856


##########
be/src/olap/in_list_predicate.cpp:
##########
@@ -138,7 +138,7 @@ IN_LIST_PRED_COLUMN_BLOCK_EVALUATE(NotInListPredicate, ==)
                         uint16_t idx = sel[i];                                                   \
                         sel[new_size] = idx;                                                     \
                         const auto& cell_value = data_array[idx];                                \
-                        DCHECK(cell_value < selected.size());                                    \
+                        DCHECK(cell_value < (int64_t)selected.size());                           \

Review Comment:
   In the original code, `-1` would be implicitly converted to uint64 and then overflow naturally, causing DCHECK to fail



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@doris.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


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