From 73c40662efecd4b640f6ba7a0dc94e790eeb9b56 Mon Sep 17 00:00:00 2001 From: David Robillard Date: Sat, 18 Jul 2020 11:30:26 +0200 Subject: Add missing const specifiers --- src/server/Buffer.cpp | 2 +- src/server/Buffer.hpp | 2 +- src/server/PortImpl.cpp | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) (limited to 'src/server') diff --git a/src/server/Buffer.cpp b/src/server/Buffer.cpp index 6894d9ca..c3430858 100644 --- a/src/server/Buffer.cpp +++ b/src/server/Buffer.cpp @@ -331,7 +331,7 @@ bool Buffer::append_event_buffer(const Buffer* buf) { auto* seq = (LV2_Atom_Sequence*)get(); - auto* bseq = (LV2_Atom_Sequence*)buf->get(); + auto* bseq = (const LV2_Atom_Sequence*)buf->get(); if (seq->atom.type == _factory.uris().atom_Chunk) { clear(); // Chunk initialized with prepare_output_write(), clear } diff --git a/src/server/Buffer.hpp b/src/server/Buffer.hpp index c67f9fd7..1cbb0f29 100644 --- a/src/server/Buffer.hpp +++ b/src/server/Buffer.hpp @@ -116,7 +116,7 @@ public: if (is_audio() || is_control()) { return samples()[offset]; } else if (_value_buffer) { - return ((LV2_Atom_Float*)value())->body; + return ((const LV2_Atom_Float*)value())->body; } return 0.0f; } diff --git a/src/server/PortImpl.cpp b/src/server/PortImpl.cpp index 5161750d..87022c27 100644 --- a/src/server/PortImpl.cpp +++ b/src/server/PortImpl.cpp @@ -494,7 +494,7 @@ PortImpl::monitor(RunContext& context, bool send_now) } else if (value && value->type == _bufs.uris().atom_Float) { /* Float sequence, monitor as a control. */ key = uris.ingen_value; - val = ((LV2_Atom_Float*)buffer(0)->value())->body; + val = ((const LV2_Atom_Float*)buffer(0)->value())->body; } else if (atom->size > sizeof(LV2_Atom_Sequence_Body)) { /* General sequence, send activity for blinkenlights. */ const int32_t one = 1; -- cgit v1.2.1