diff --git a/src/detail/vst3/os/osutil.h b/src/detail/vst3/os/osutil.h index 56524ca7..76ffc1f1 100644 --- a/src/detail/vst3/os/osutil.h +++ b/src/detail/vst3/os/osutil.h @@ -21,6 +21,10 @@ class State State(std::function on, std::function off) : _on(on), _off(off) { } + ~State() + { + off(); + } void on() { if (!_state)