DPF

DISTRHO Plugin Framework
Log | Files | Refs | Submodules | README | LICENSE

commit 9aec1687c8ef5304efd8da6a65bdd1d0913fa612
parent 8f478f979f70b837a70259b1123da7162cbae35b
Author: falkTX <falktx@falktx.com>
Date:   Sun, 19 Sep 2021 13:27:18 +0100

And even more fixes

Signed-off-by: falkTX <falktx@falktx.com>

Diffstat:
Mdgl/src/WindowPrivateData.cpp | 4++--
Mdistrho/src/DistrhoPluginJACK.cpp | 2+-
Mdistrho/src/DistrhoPluginLV2.cpp | 2+-
3 files changed, 4 insertions(+), 4 deletions(-)

diff --git a/dgl/src/WindowPrivateData.cpp b/dgl/src/WindowPrivateData.cpp @@ -542,13 +542,13 @@ bool Window::PrivateData::openFileBrowser(const Window::FileBrowserOptions& opti // set start directory in UTF-16 encoding std::vector<WCHAR> startDirW; startDirW.resize(startDir.length() + 1); - if (MultiByteToWideChar(CP_UTF8, 0, startDir.buffer(), -1, startDirW.data(), startDirW.size())) + if (MultiByteToWideChar(CP_UTF8, 0, startDir.buffer(), -1, startDirW.data(), static_cast<int>(startDirW.size()))) ofn.lpstrInitialDir = startDirW.data(); // set title in UTF-16 encoding std::vector<WCHAR> titleW; titleW.resize(title.length() + 1); - if (MultiByteToWideChar(CP_UTF8, 0, title.buffer(), -1, titleW.data(), titleW.size())) + if (MultiByteToWideChar(CP_UTF8, 0, title.buffer(), -1, titleW.data(), static_cast<int>(titleW.size()))) ofn.lpstrTitle = titleW.data(); // prepare a buffer to receive the result diff --git a/distrho/src/DistrhoPluginJACK.cpp b/distrho/src/DistrhoPluginJACK.cpp @@ -469,7 +469,7 @@ protected: MidiEvent& midiEvent(midiEvents[midiEventCount++]); midiEvent.frame = jevent.time; - midiEvent.size = jevent.size; + midiEvent.size = static_cast<uint32_t>(jevent.size); if (midiEvent.size > MidiEvent::kDataSize) midiEvent.dataExt = jevent.buffer; diff --git a/distrho/src/DistrhoPluginLV2.cpp b/distrho/src/DistrhoPluginLV2.cpp @@ -708,7 +708,7 @@ public: const String& value(cit->second); // set msg size (key + value + separator + 2x null terminator) - const size_t msgSize = key.length()+value.length()+3; + const uint32_t msgSize = static_cast<uint32_t>(key.length()+value.length())+3U; if (sizeof(LV2_Atom_Event) + msgSize > capacity - fEventsOutData.offset) {