summaryrefslogtreecommitdiff
path: root/src/lib
diff options
context:
space:
mode:
Diffstat (limited to 'src/lib')
-rw-r--r--src/lib/encode_server.cc8
-rw-r--r--src/lib/image.cc4
2 files changed, 6 insertions, 6 deletions
diff --git a/src/lib/encode_server.cc b/src/lib/encode_server.cc
index 80d25a358..9a7c622e0 100644
--- a/src/lib/encode_server.cc
+++ b/src/lib/encode_server.cc
@@ -47,7 +47,7 @@ LIBDCP_ENABLE_WARNINGS
#include <fmt/format.h>
#include <boost/algorithm/string.hpp>
#include <boost/scoped_array.hpp>
-#ifdef HAVE_VALGRIND_H
+#ifdef DCPOMATIC_HAVE_VALGRIND_MEMCHECK_H
#include <valgrind/memcheck.h>
#endif
#include <string>
@@ -74,10 +74,10 @@ using dcp::Size;
EncodeServer::EncodeServer (bool verbose, int num_threads)
-#if !defined(RUNNING_ON_VALGRIND) || RUNNING_ON_VALGRIND == 0
- : Server (ENCODE_FRAME_PORT)
+#ifdef DCPOMATIC_HAVE_VALGRIND_MEMCHECK_H
+ : Server(ENCODE_FRAME_PORT, RUNNING_ON_VALGRIND ? 2400 : 30)
#else
- : Server (ENCODE_FRAME_PORT, 2400)
+ : Server(ENCODE_FRAME_PORT)
#endif
, _verbose (verbose)
, _num_threads (num_threads)
diff --git a/src/lib/image.cc b/src/lib/image.cc
index e7cfd2dcd..de57ee877 100644
--- a/src/lib/image.cc
+++ b/src/lib/image.cc
@@ -44,7 +44,7 @@ extern "C" {
#include <libswscale/swscale.h>
}
LIBDCP_ENABLE_WARNINGS
-#if HAVE_VALGRIND_MEMCHECK_H
+#if DCPOMATIC_HAVE_VALGRIND_MEMCHECK_H
#include <valgrind/memcheck.h>
#endif
#include <iostream>
@@ -1303,7 +1303,7 @@ Image::allocate()
^^^^ out of bounds
*/
_data[i] = (uint8_t *) wrapped_av_malloc(_stride[i] * (sample_size(i).height + 1) + ALIGNMENT);
-#if HAVE_VALGRIND_MEMCHECK_H
+#ifdef DCPOMATIC_HAVE_VALGRIND_MEMCHECK_H
/* The data between the end of the line size and the stride is undefined but processed by
libswscale, causing lots of valgrind errors. Mark it all defined to quell these errors.
*/