]> sigrok.org Git - pulseview.git/commit
Free unused segment memory after acquisition
authorSoeren Apel <redacted>
Wed, 8 Feb 2017 19:33:48 +0000 (20:33 +0100)
committerSoeren Apel <redacted>
Wed, 8 Feb 2017 19:33:48 +0000 (20:33 +0100)
commit5e6967cb2bcacbfb9e5b627becb6752621949998
tree14a21672a23f82d20325919fe00032d1a7f9e0f3
parent332c6dd8ebbbd24a5efdf3761f94a48deb9d721a
Free unused segment memory after acquisition

Segments allocate chunks of MaxChunkSize bytes each.
Most likely, the last allocated chunk isn't fully used,
so there's memory going to waste. This patch fixes this
by allocating a chunk of the required size that replaces
the last standard chunk.
pv/data/segment.cpp
pv/data/segment.hpp
pv/session.cpp
pv/session.hpp