MCPcopy Create free account
hub / github.com/google/snappy / SetExpectedLength

Method SetExpectedLength

snappy.cc:2308–2312  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

2306 op_limit_min_slop_(dst) {} // Safe default see invariant.
2307
2308 inline void SetExpectedLength(size_t len) {
2309 op_limit_ = op_ + len;
2310 // Prevent pointer from being past the buffer.
2311 op_limit_min_slop_ = op_limit_ - std::min<size_t>(kSlopBytes - 1, len);
2312 }
2313
2314 inline bool CheckLength() const { return op_ == op_limit_; }
2315

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected