MCPcopy Create free account
hub / github.com/KDE/labplot / nextLogContainer

Method nextLogContainer

src/3rdparty/vector_blf/src/Vector/BLF/UncompressedFile.cpp:224–240  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

222}
223
224void UncompressedFile::nextLogContainer() {
225 /* mutex lock */
226 std::lock_guard<std::mutex> lock(m_mutex);
227
228 /* find starting log container */
229 std::shared_ptr<LogContainer> logContainer = logContainerContaining(m_tellp);
230 if (logContainer) {
231 /* offset to write */
232 std::streamoff offset = m_tellp - logContainer->filePosition;
233
234 /* resize logContainer, if it's not already a newly created one */
235 if (offset > 0) {
236 logContainer->uncompressedFile.resize(offset);
237 logContainer->uncompressedFileSize = offset;
238 }
239 }
240}
241
242std::streamsize UncompressedFile::fileSize() const {
243 /* mutex lock */

Callers 1

closeMethod · 0.80

Calls 1

resizeMethod · 0.45

Tested by

no test coverage detected