Uh oh!
There was an error while loading. Please reload this page.
[fix](multi table) do not use strlen to calculate the length of msg - #40367
Conversation
doris-robot
commented
Sep 4, 2024
Thank you for your contribution to Apache Doris. Since 2024-03-18, the Document has been moved to doris-website. |
sollhui
commented
Sep 4, 2024
run buildall |
clang-tidy review says "All clean, LGTM! 👍" |
doris-robot
commented
Sep 4, 2024
TeamCity be ut coverage result: |
sollhui
commented
Sep 5, 2024
run buildall |
doris-robot
commented
Sep 5, 2024
TeamCity be ut coverage result: |
doris-robot
commented
Sep 5, 2024
TPC-H: Total hot run time: 38003 ms |
doris-robot
commented
Sep 5, 2024
TPC-DS: Total hot run time: 193052 ms |
doris-robot
commented
Sep 5, 2024
ClickBench: Total hot run time: 32.71 s |
PR approved by at least one committer and no changes requested. |
PR approved by anyone and no changes requested. |
…40367) (#40500) pick #40367 Meet code dump when using single stream multi table load: ``` SUMMARY: AddressSanitizer: heap-buffer-overflow /root/doris/be/src/io/fs/multi_table_pipe.cpp:99:22 in doris::io::MultiTablePipe::dispatch(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const&, char const*, unsigned long, doris::Status (doris::io::KafkaConsumerPipe::*)(char const*, unsigned long)) ``` 1. It is hard to guaranteed that msg is a C-style string ending in '\0' character. If not, it may cause the core dump to access memory out of bounds. 2. It is not need to calculate the length of msg twice. Therefore, deleting the logic that using strlen to calculate the length of msg.
…40367) (#40511) pick #40367 Meet code dump when using single stream multi table load: ``` SUMMARY: AddressSanitizer: heap-buffer-overflow /root/doris/be/src/io/fs/multi_table_pipe.cpp:99:22 in doris::io::MultiTablePipe::dispatch(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const&, char const*, unsigned long, doris::Status (doris::io::KafkaConsumerPipe::*)(char const*, unsigned long)) ``` 1. It is hard to guaranteed that msg is a C-style string ending in '\0' character. If not, it may cause the core dump to access memory out of bounds. 2. It is not need to calculate the length of msg twice. Therefore, deleting the logic that using strlen to calculate the length of msg.
…40367) Meet code dump when using single stream multi table load: ``` SUMMARY: AddressSanitizer: heap-buffer-overflow /root/doris/be/src/io/fs/multi_table_pipe.cpp:99:22 in doris::io::MultiTablePipe::dispatch(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const&, char const*, unsigned long, doris::Status (doris::io::KafkaConsumerPipe::*)(char const*, unsigned long)) ``` 1. It is hard to guaranteed that msg is a C-style string ending in '\0' character. If not, it may cause the core dump to access memory out of bounds. 2. It is not need to calculate the length of msg twice. Therefore, deleting the logic that using strlen to calculate the length of msg.
…pache#40367) Meet code dump when using single stream multi table load: ``` SUMMARY: AddressSanitizer: heap-buffer-overflow /root/doris/be/src/io/fs/multi_table_pipe.cpp:99:22 in doris::io::MultiTablePipe::dispatch(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const&, char const*, unsigned long, doris::Status (doris::io::KafkaConsumerPipe::*)(char const*, unsigned long)) ``` 1. It is hard to guaranteed that msg is a C-style string ending in '\0' character. If not, it may cause the core dump to access memory out of bounds. 2. It is not need to calculate the length of msg twice. Therefore, deleting the logic that using strlen to calculate the length of msg.
Meet code dump when using single stream multi table load:
Therefore, deleting the logic that using strlen to calculate the length of msg.