Uh oh!
There was an error while loading. Please reload this page.
[fix](snapshot-loader) Fix be crash caused by deref end() iterator - #32489
Conversation
The standard said that the input parameter `pos` of std::vector::erase must be valid and dereferenceable, the `end()` iterator cannot be used as a value of `pos`. I did some tests and the crash only occurs when the vector is empty. Fortunately `local_files` is usually not empty.
doris-robot
commented
Mar 19, 2024
Thank you for your contribution to Apache Doris. Since 2024-03-18, the Document has been moved to doris-website. |
w41ter
commented
Mar 19, 2024
run buildall |
PR approved by anyone and no changes requested. |
clang-tidy review says "All clean, LGTM! 👍" |
doris-robot
commented
Mar 19, 2024
TeamCity be ut coverage result: |
PR approved by at least one committer and no changes requested. |
…pache#32489) The standard said that the input parameter `pos` of std::vector::erase must be valid and dereferenceable, the `end()` iterator cannot be used as a value of `pos`. I did some tests and the crash only occurs when the vector is empty. Fortunately `local_files` is usually not empty.
…32489) The standard said that the input parameter `pos` of std::vector::erase must be valid and dereferenceable, the `end()` iterator cannot be used as a value of `pos`. I did some tests and the crash only occurs when the vector is empty. Fortunately `local_files` is usually not empty.
…32489) The standard said that the input parameter `pos` of std::vector::erase must be valid and dereferenceable, the `end()` iterator cannot be used as a value of `pos`. I did some tests and the crash only occurs when the vector is empty. Fortunately `local_files` is usually not empty.
…pache#32489) The standard said that the input parameter `pos` of std::vector::erase must be valid and dereferenceable, the `end()` iterator cannot be used as a value of `pos`. I did some tests and the crash only occurs when the vector is empty. Fortunately `local_files` is usually not empty.
…pache#32489) The standard said that the input parameter `pos` of std::vector::erase must be valid and dereferenceable, the `end()` iterator cannot be used as a value of `pos`. I did some tests and the crash only occurs when the vector is empty. Fortunately `local_files` is usually not empty.
Proposed changes
Issue Number: close #xxx
The standard said that the input parameter
posof std::vector::erase must be valid and dereferenceable, theend()iterator cannot be used as a value ofpos. I did some tests and the crash only occurs when the vector is empty. Fortunatelylocal_filesis usually not empty.The crash stack is:
Further comments
If this is a relatively large or complex change, kick off the discussion at dev@doris.apache.org by explaining why you chose the solution you did and what alternatives you considered, etc...