yiguolei commented on code in PR #19472:
URL: https://github.com/apache/doris/pull/19472#discussion_r1193768400
##########
be/src/olap/rowset/segment_v2/page_io.cpp:
##########
@@ -143,8 +143,8 @@ Status PageIO::read_and_decompress_page(const
PageReadOptions& opts, PageHandle*
}
// hold compressed page at first, reset to decompressed page later
- std::unique_ptr<char[]> page(new char[page_size]);
- Slice page_slice(page.get(), page_size);
+ std::unique_ptr<DataPage<>> page = std::make_unique<DataPage<>>(page_size);
Review Comment:
Here
##########
be/src/olap/rowset/segment_v2/page_io.cpp:
##########
@@ -177,12 +177,12 @@ Status PageIO::read_and_decompress_page(const
PageReadOptions& opts, PageHandle*
return Status::Corruption("Bad page: page is compressed but codec
is NO_COMPRESSION");
}
SCOPED_RAW_TIMER(&opts.stats->decompress_ns);
- std::unique_ptr<char[]> decompressed_page(
- new char[footer->uncompressed_size() + footer_size + 4]);
+ std::unique_ptr<DataPage<>> decompressed_page =
Review Comment:
Here
--
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]