MCPcopy Create free account
hub / github.com/ceph/ceph / decompress

Method decompress

src/msg/async/compression_onwire.cc:60–79  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

58}
59
60std::optional<ceph::bufferlist> RxHandler::decompress(const ceph::bufferlist &input)
61{
62 ceph::bufferlist out;
63 if (input.length() == 0) {
64 ldout(m_cct, 20) << __func__
65 << " discovered an empty segment, skipping decompression without aborting"
66 << dendl;
67 out.clear();
68 return out;
69 }
70
71 std::optional<int32_t> compressor_message;
72 if (m_compressor->decompress(input, out, compressor_message)) {
73 return {};
74 } else {
75 ldout(m_cct, 20) << __func__ << " compressed.length()=" << input.length()
76 << " uncompressed.length()=" << out.length() << dendl;
77 return out;
78 }
79}
80
81void TxHandler::done()
82{

Callers 1

Calls 2

lengthMethod · 0.45
clearMethod · 0.45

Tested by

no test coverage detected