From 94014dc5d56a5762a0cec83116255ae44ee46527 Mon Sep 17 00:00:00 2001 From: Robin Gareus Date: Mon, 10 Aug 2015 22:47:32 +0200 Subject: [PATCH] fix video-metadata for windows. --- gtk2_ardour/transcode_ffmpeg.cc | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/gtk2_ardour/transcode_ffmpeg.cc b/gtk2_ardour/transcode_ffmpeg.cc index 94f8527cbb..efe4e44ebe 100644 --- a/gtk2_ardour/transcode_ffmpeg.cc +++ b/gtk2_ardour/transcode_ffmpeg.cc @@ -298,7 +298,15 @@ TranscodeFfmpeg::format_metadata (std::string key, std::string value) size_t len = key.length() + v1.length() + 4; char *mds = (char*) calloc(len, sizeof(char)); +#ifdef PLATFORM_WINDOWS + /* SystemExec::make_wargs() adds quotes around the complete argument + * windows uses CreateProcess() with a parameter string + * (and not an array list of separate arguments) + */ + snprintf(mds, len, "%s=%s", key.c_str(), v1.c_str()); +#else snprintf(mds, len, "%s=\"%s\"", key.c_str(), v1.c_str()); +#endif return mds; }