eldenmoon opened a new pull request, #28536:
URL: https://github.com/apache/doris/pull/28536

   …_in_blocks`
   
   Otherwise using the stale `_row_in_blocks` will result in heap-use-after-free
   
   ```
   ==2695213==ERROR: AddressSanitizer: heap-buffer-overflow on address 
0x62900122e210 at pc 0x56524744aecf bp 0x7f62c595ef7
   0 sp 0x7f62c595ef68
   READ of size 8 at 0x62900122e210 thread T1627 (MemTableFlushTh)
       #0 0x56524744aece in 
doris::vectorized::ColumnVector<long>::insert_indices_from(doris::vectorized::IColumn
 const&, unsigned int const*, unsigned int const*) 
/mnt/disk2/lihangyu/doris/be/src/vec/columns/column_vector.cpp:378:33
       #1 0x5652472a7538 in 
doris::vectorized::ColumnNullable::insert_indices_from(doris::vectorized::IColumn
 const&, unsigned int const*, unsigned int const*) 
/mnt/disk2/lihangyu/doris/be/src/vec/columns/column_nullable.cpp:310:25
       #2 0x56524782a62a in 
doris::vectorized::MutableBlock::add_rows(doris::vectorized::Block const*, 
unsigned int const*, unsigned int const*) 
/mnt/disk2/lihangyu/doris/be/src/vec/core/block.cpp:961:14
       #3 0x565233f187ae in 
doris::MemTable::_put_into_output(doris::vectorized::Block&) 
/mnt/disk2/lihangyu/doris/be/src/olap/memtable.cpp:248:27
       #4 0x565233f1db66 in doris::MemTable::to_block() 
/mnt/disk2/lihangyu/doris/be/src/olap/memtable.cpp:496:13
       #5 0x565233efae60 in 
doris::FlushToken::_do_flush_memtable(doris::MemTable*, int, long*) 
/mnt/disk2/lihangyu/doris/be/src/olap/memtable_flush_executor.cpp:121:62
       #6 0x565233efc8d6 in 
doris::FlushToken::_flush_memtable(doris::MemTable*, int, long) 
/mnt/disk2/lihangyu/doris/be/src/olap/memtable_flush_executor.cpp:150:16
       #7 0x565233f0c5eb in doris::MemtableFlushTask::run() 
/mnt/disk2/lihangyu/doris/be/src/olap/memtable_flush_executor.cpp:58:23
   ```
   
   ## Proposed changes
   
   Issue Number: close #xxx
   
   <!--Describe your changes.-->
   
   ## Further comments
   
   If this is a relatively large or complex change, kick off the discussion at 
[d...@doris.apache.org](mailto:d...@doris.apache.org) by explaining why you 
chose the solution you did and what alternatives you considered, etc...
   
   


-- 
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-unsubscr...@doris.apache.org

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


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

Reply via email to