yangzhg commented on a change in pull request #8193:
URL: https://github.com/apache/incubator-doris/pull/8193#discussion_r812530938



##########
File path: be/src/olap/rowset/segment_v2/binary_dict_page.cpp
##########
@@ -207,71 +200,54 @@ Status BinaryDictPageDecoder::init() {
         // copy the codewords into a temporary buffer first
         // And then copy the strings corresponding to the codewords to the 
destination buffer
         TypeInfo* type_info = get_scalar_type_info(OLAP_FIELD_TYPE_INT);
-
         RETURN_IF_ERROR(ColumnVectorBatch::create(0, false, type_info, 
nullptr, &_batch));
-        _data_page_decoder.reset(_bit_shuffle_ptr = new 
BitShufflePageDecoder<OLAP_FIELD_TYPE_INT>(_data, _options));
+        auto status = (new (&_bit_shuffle) 
BitShufflePageDecoder<OLAP_FIELD_TYPE_INT>(_data, _options))->init();
+        if (!status.ok()) return status;

Review comment:
       why not use `RETURN_IF_ERROR()`




-- 
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: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]



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

Reply via email to