MCPcopy Create free account
hub / github.com/BatchDrake/SigDigger / allocBuffer

Method allocBuffer

Default/GenericInspector/TVProcessorWorker.cpp:66–81  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

64}
65
66std::vector<SUFLOAT> *
67TVProcessorWorker::allocBuffer(std::vector<SUFLOAT> &buffer)
68{
69 std::vector<SUFLOAT> *entry;
70
71 this->pendingDataMutex.lock();
72 entry = popFromList(this->freeList);
73 this->pendingDataMutex.unlock();
74
75 if (entry == nullptr)
76 entry = new std::vector<SUFLOAT>;
77
78 *entry = std::move(buffer);
79
80 return entry;
81}
82
83void
84TVProcessorWorker::putPendingBuffer(std::vector<SUFLOAT> *buffer)

Callers 1

pushDataMethod · 0.95

Calls 2

lockMethod · 0.80
unlockMethod · 0.80

Tested by

no test coverage detected