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

lihaopeng pushed a commit to branch branch-2.0
in repository https://gitbox.apache.org/repos/asf/doris.git


The following commit(s) were added to refs/heads/branch-2.0 by this push:
     new 97de87e007f [Fix](ser) serialize bitmap/hll some not fixed length 
object maybe over INT_MAX (#30780)
97de87e007f is described below

commit 97de87e007fce7ca36da02b02c3483e205b1a30a
Author: HappenLee <happen...@hotmail.com>
AuthorDate: Sun Feb 4 14:06:14 2024 +0800

    [Fix](ser) serialize bitmap/hll some not fixed length object maybe over 
INT_MAX (#30780)
---
 be/src/vec/data_types/data_type_bitmap.cpp        | 2 +-
 be/src/vec/data_types/data_type_hll.cpp           | 2 +-
 be/src/vec/data_types/data_type_quantilestate.cpp | 2 +-
 3 files changed, 3 insertions(+), 3 deletions(-)

diff --git a/be/src/vec/data_types/data_type_bitmap.cpp 
b/be/src/vec/data_types/data_type_bitmap.cpp
index 6cccf914f14..ec145db9917 100644
--- a/be/src/vec/data_types/data_type_bitmap.cpp
+++ b/be/src/vec/data_types/data_type_bitmap.cpp
@@ -39,7 +39,7 @@ int64_t 
DataTypeBitMap::get_uncompressed_serialized_bytes(const IColumn& column,
     auto& data_column = assert_cast<const ColumnBitmap&>(*ptr);
 
     auto allocate_len_size = sizeof(size_t) * (column.size() + 1);
-    auto allocate_content_size = 0;
+    size_t allocate_content_size = 0;
     for (size_t i = 0; i < column.size(); ++i) {
         auto& bitmap = const_cast<BitmapValue&>(data_column.get_element(i));
         allocate_content_size += bitmap.getSizeInBytes();
diff --git a/be/src/vec/data_types/data_type_hll.cpp 
b/be/src/vec/data_types/data_type_hll.cpp
index efb3e735a2e..92c585af51a 100644
--- a/be/src/vec/data_types/data_type_hll.cpp
+++ b/be/src/vec/data_types/data_type_hll.cpp
@@ -85,7 +85,7 @@ int64_t DataTypeHLL::get_uncompressed_serialized_bytes(const 
IColumn& column,
     auto& data_column = assert_cast<const ColumnHLL&>(*ptr);
 
     auto allocate_len_size = sizeof(size_t) * (column.size() + 1);
-    auto allocate_content_size = 0;
+    size_t allocate_content_size = 0;
     for (size_t i = 0; i < column.size(); ++i) {
         auto& hll = const_cast<HyperLogLog&>(data_column.get_element(i));
         allocate_content_size += hll.max_serialized_size();
diff --git a/be/src/vec/data_types/data_type_quantilestate.cpp 
b/be/src/vec/data_types/data_type_quantilestate.cpp
index a6a37e1f07b..c69371d73d5 100644
--- a/be/src/vec/data_types/data_type_quantilestate.cpp
+++ b/be/src/vec/data_types/data_type_quantilestate.cpp
@@ -36,7 +36,7 @@ int64_t 
DataTypeQuantileState<T>::get_uncompressed_serialized_bytes(const IColum
     auto& data_column = assert_cast<const ColumnQuantileState<T>&>(*ptr);
 
     auto allocate_len_size = sizeof(size_t) * (column.size() + 1);
-    auto allocate_content_size = 0;
+    size_t allocate_content_size = 0;
     for (size_t i = 0; i < column.size(); ++i) {
         auto& quantile_state = 
const_cast<QuantileState<T>&>(data_column.get_element(i));
         allocate_content_size += quantile_state.get_serialized_size();


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

Reply via email to