diff --git a/src/common/events.h b/src/common/events.h index fb23ce08..1efb6509 100644 --- a/src/common/events.h +++ b/src/common/events.h @@ -269,9 +269,9 @@ void passthrough_event(boost::asio::local::stream_protocol::socket& socket, // stored in an array to which a pointer is stored in // `data`, with the return value from the event determines // how much data the plugin has written - const uint8_t* chunk_data = *static_cast(data); - return std::vector(chunk_data, - chunk_data + return_value); + return std::vector( + binary_buffer.begin(), + binary_buffer.begin() + return_value); }, [&](VstIOProperties& props) -> EventResposnePayload { return props;