From 94431ea9decdd8d6f9a1c377c1e7ee621cc19bb7 Mon Sep 17 00:00:00 2001 From: Hyunjin Song Date: Sun, 1 Mar 2020 12:03:49 +0900 Subject: [PATCH] RemoteVstPlugin: fix issues with FXP/FXB files on Windows (#5411) --- plugins/vst_base/RemoteVstPlugin.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/plugins/vst_base/RemoteVstPlugin.cpp b/plugins/vst_base/RemoteVstPlugin.cpp index 15a56e869..be92126e3 100644 --- a/plugins/vst_base/RemoteVstPlugin.cpp +++ b/plugins/vst_base/RemoteVstPlugin.cpp @@ -1286,7 +1286,7 @@ void RemoteVstPlugin::savePreset( const std::string & _file ) if (!isPreset &&!chunky) uIntToFile = (unsigned int) m_plugin->numPrograms; pBank->numPrograms = endian_swap( uIntToFile ); - FILE * stream = F_OPEN_UTF8( _file, "w" ); + FILE * stream = F_OPEN_UTF8( _file, "wb" ); if (!stream) { fprintf( stderr, @@ -1344,7 +1344,7 @@ void RemoteVstPlugin::loadPresetFile( const std::string & _file ) unsigned int * pLen = new unsigned int[ 1 ]; unsigned int len = 0; sBank * pBank = (sBank*) new char[ sizeof( sBank ) ]; - FILE * stream = F_OPEN_UTF8( _file, "r" ); + FILE * stream = F_OPEN_UTF8( _file, "rb" ); if (!stream) { fprintf( stderr,