diff options
author | falkTX <falktx@gmail.com> | 2016-02-23 09:55:27 +0100 |
---|---|---|
committer | falkTX <falktx@gmail.com> | 2016-02-23 09:55:27 +0100 |
commit | 81529dd0aaaedc29f71349f381cb81b39830969c (patch) | |
tree | 3318b5077c7b167edd3b1396a6ed43f07883d4f6 /distrho/src/DistrhoPluginVST.cpp | |
parent | d1e127289c4f3f51d34177ed3adb67f2e75925fe (diff) |
Fix VST chunk save
Thanks fundamental for spotting it
Diffstat (limited to 'distrho/src/DistrhoPluginVST.cpp')
-rw-r--r-- | distrho/src/DistrhoPluginVST.cpp | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/distrho/src/DistrhoPluginVST.cpp b/distrho/src/DistrhoPluginVST.cpp index 92129c4a..99c1794d 100644 --- a/distrho/src/DistrhoPluginVST.cpp +++ b/distrho/src/DistrhoPluginVST.cpp @@ -340,6 +340,8 @@ public: intptr_t vst_dispatcher(const int32_t opcode, const int32_t index, const intptr_t value, void* const ptr, const float opt) { + intptr_t ret = 0; + switch (opcode) { case effGetProgram: @@ -512,7 +514,7 @@ public: { fStateChunk = new char[1]; fStateChunk[0] = '\0'; - return 1; + ret = 1; } else { @@ -554,11 +556,11 @@ public: fStateChunk[i] = '\0'; } - return chunkSize; + ret = chunkSize; } *(void**)ptr = fStateChunk; - break; + return ret; case effSetChunk: { |