diff --git a/src/villas-relay.hpp b/src/villas-relay.hpp index 5d0bb2fe1..ad3037384 100644 --- a/src/villas-relay.hpp +++ b/src/villas-relay.hpp @@ -31,6 +31,7 @@ typedef std::string Identifier; class Frame : public std::vector { public: Frame() { + reserve(LWS_PRE); /* lws_write() requires LWS_PRE bytes in front of the payload */ insert(end(), LWS_PRE, 0); }