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

yiguolei pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/doris.git


The following commit(s) were added to refs/heads/master by this push:
     new 5d627e41a4 [fix](array-type) fix the be core dump when import number 
larger than uint64 (#11853)
5d627e41a4 is described below

commit 5d627e41a4bc321faa9373b6772a778a7ba112d8
Author: carlvinhust2012 <[email protected]>
AuthorDate: Wed Aug 24 08:51:12 2022 +0800

    [fix](array-type) fix the be core dump when import number larger than 
uint64 (#11853)
    
    Co-authored-by: hucheng01 <[email protected]>
---
 be/src/util/array_parser.h | 8 +++++++-
 1 file changed, 7 insertions(+), 1 deletion(-)

diff --git a/be/src/util/array_parser.h b/be/src/util/array_parser.h
index bbdf2571f0..29d90ff1e6 100644
--- a/be/src/util/array_parser.h
+++ b/be/src/util/array_parser.h
@@ -171,7 +171,13 @@ private:
         case TYPE_LARGEINT: {
             __int128 value = 0;
             if (iterator->IsNumber()) {
-                value = iterator->GetUint64();
+                if (iterator->IsUint64()) {
+                    value = iterator->GetUint64();
+                } else {
+                    return Status::RuntimeError(
+                            "rapidjson can't parse the number larger than 
Uint64, please use "
+                            "String to parse as LARGEINT");
+                }
             } else {
                 std::string_view view(iterator->GetString(), 
iterator->GetStringLength());
                 std::stringstream stream;


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

Reply via email to