TooB Spectum Analyzer
This commit is contained in:
+1
-1
@@ -658,7 +658,7 @@ void Lv2Effect::WriteAtom(json_writer &writer, LV2_Atom*pAtom)
|
||||
);
|
||||
} else if (pAtom->type == uris.atom_String)
|
||||
{
|
||||
const char *p = (const char*) (((char*) pAtom) + sizeof(LV2_Atom_String));
|
||||
const char *p = (((const char*) pAtom) + sizeof(LV2_Atom_String));
|
||||
writer.write(
|
||||
p
|
||||
);
|
||||
|
||||
+6
-2
@@ -71,7 +71,11 @@ LV2_Worker_Status Worker::worker_respond_fn(LV2_Worker_Respond_Handle handle, ui
|
||||
|
||||
LV2_Worker_Status Worker::WorkerResponse(uint32_t size, const void *data)
|
||||
{
|
||||
if (responseRingBuffer.write(sizeof(size), (uint8_t *)&size))
|
||||
if (responseRingBuffer.writeSpace() < sizeof(size)+size)
|
||||
{
|
||||
return LV2_WORKER_ERR_NO_SPACE;
|
||||
}
|
||||
if (!responseRingBuffer.write(sizeof(size), (uint8_t *)&size))
|
||||
{
|
||||
return LV2_WORKER_ERR_NO_SPACE;
|
||||
}
|
||||
@@ -107,7 +111,7 @@ void Worker::ThreadProc()
|
||||
{
|
||||
return;
|
||||
}
|
||||
size_t size;
|
||||
uint32_t size;
|
||||
while (requestRingBuffer.readSpace() > sizeof(size))
|
||||
{
|
||||
if (!requestRingBuffer.read(sizeof(size), (uint8_t *)&size))
|
||||
|
||||
Reference in New Issue
Block a user