From d18b247a05906aec00d684996c493b5444a46e77 Mon Sep 17 00:00:00 2001 From: Robin Gareus Date: Mon, 19 Nov 2018 12:50:38 +0100 Subject: [PATCH] Fix Windows and Mac Builds * missing include for locale_to_utf8 (amend 4c6ff5f7e7) * avoid void* arithemtic (amend 103ef2ba) --- libs/ardour/video_tools_paths.cc | 1 + libs/pbd/system_exec.cc | 4 ++-- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/libs/ardour/video_tools_paths.cc b/libs/ardour/video_tools_paths.cc index 7107323de9..2021018829 100644 --- a/libs/ardour/video_tools_paths.cc +++ b/libs/ardour/video_tools_paths.cc @@ -29,6 +29,7 @@ #include "pbd/file_utils.h" +#include #include #include diff --git a/libs/pbd/system_exec.cc b/libs/pbd/system_exec.cc index ed36c507ff..cc5d8d99fe 100644 --- a/libs/pbd/system_exec.cc +++ b/libs/pbd/system_exec.cc @@ -601,7 +601,7 @@ SystemExec::write_to_stdin(const void* data, size_t bytes) c=0; while (c < bytes) { - if (!WriteFile(stdinP[1], data+c, bytes-c, &r, NULL)) { + if (!WriteFile(stdinP[1], &((const char*)data)[c], bytes - c, &r, NULL)) { if (GetLastError() == 0xE8 /*NT_STATUS_INVALID_USER_BUFFER*/) { Sleep(100); continue; @@ -965,7 +965,7 @@ SystemExec::write_to_stdin(const void* data, size_t bytes) c=0; while (c < bytes) { for (;;) { - r=::write(pin[1], data+c, bytes-c); + r = ::write(pin[1], &((const char*)data)[c], bytes - c); if (r < 0 && (errno == EINTR || errno == EAGAIN)) { sleep(1); continue;