summaryrefslogtreecommitdiffstats
path: root/src/engine/ObjectBuffer.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/engine/ObjectBuffer.cpp')
-rw-r--r--src/engine/ObjectBuffer.cpp10
1 files changed, 8 insertions, 2 deletions
diff --git a/src/engine/ObjectBuffer.cpp b/src/engine/ObjectBuffer.cpp
index a4108ba1..2c319b34 100644
--- a/src/engine/ObjectBuffer.cpp
+++ b/src/engine/ObjectBuffer.cpp
@@ -55,8 +55,7 @@ ObjectBuffer::ObjectBuffer(BufferFactory& factory, size_t capacity)
exit(EXIT_FAILURE);
}
- object()->type = 0;
- object()->size = capacity;
+ clear();
}
@@ -124,5 +123,12 @@ ObjectBuffer::port_data(PortType port_type) const
}
+void
+ObjectBuffer::prepare_write(Context& context)
+{
+ _buf->size = _size - sizeof(LV2_Object);
+}
+
+
} // namespace Ingen