MCPcopy Create free account
hub / github.com/Serial-Studio/Serial-Studio / SetFilePosition

Function SetFilePosition

lib/mdflib/mdflib/src/mdfblock.cpp:155–161  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

153}
154
155void SetFilePosition(std::streambuf& buffer, int64_t position) {
156 const auto pos = buffer.pubseekpos(
157 static_cast<std::streambuf::pos_type>(position));
158 if (pos < 0) {
159 throw std::ios_base::failure("Failed to set a stream position");
160 }
161}
162
163void SetFirstFilePosition(std::streambuf& buffer) {
164 const auto pos = buffer.pubseekoff(0, std::ios_base::beg);

Callers 15

ReadHeaderMethod · 0.85
ReadMethod · 0.85
ReadDataMethod · 0.85
ReadRangeDataMethod · 0.85
CopyDataToFileMethod · 0.85
CopyDataToBufferMethod · 0.85
CopyDataToFileMethod · 0.85
CopyDataToBufferMethod · 0.85
ReadDataMethod · 0.85
ReadBlockListMethod · 0.85
ReadLinkListMethod · 0.85
ReadMethod · 0.85

Calls 1

failureFunction · 0.85

Tested by

no test coverage detected