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

dataroaring 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 a6be436acda [Fix](load) Restrict the import of VARCHAR(0) data to 
avoid coredump (#40940) (#40976)
a6be436acda is described below

commit a6be436acda5dfc15b1567b89b10414e3374950f
Author: Xin Liao <[email protected]>
AuthorDate: Thu Sep 19 22:18:48 2024 +0800

    [Fix](load) Restrict the import of VARCHAR(0) data to avoid coredump 
(#40940) (#40976)
    
    cherry pick from https://github.com/apache/doris/pull/40940
---
 be/src/vec/sink/vtablet_sink.cpp | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/be/src/vec/sink/vtablet_sink.cpp b/be/src/vec/sink/vtablet_sink.cpp
index 4bf4cb0ff09..cd7a0d8c083 100644
--- a/be/src/vec/sink/vtablet_sink.cpp
+++ b/be/src/vec/sink/vtablet_sink.cpp
@@ -1733,7 +1733,7 @@ Status VOlapTableSink::_validate_column(RuntimeState* 
state, const TypeDescripto
 
         size_t limit = config::string_type_length_soft_limit_bytes;
         // when type.len is negative, std::min will return overflow value, so 
we need to check it
-        if (type.len > 0) {
+        if (type.len >= 0) {
             limit = std::min(config::string_type_length_soft_limit_bytes, 
type.len);
         }
 


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to