1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43
|
From: Steve Langasek <steve.langasek@ubuntu.com>
Date: Sat, 10 Oct 2020 12:25:53 +0200
Subject: limit the number of openmp threads used to 1
Bug-Ubuntu: https://bugs.launchpad.net/bugs/1549942
The php-imagick 3.4.0 test suite fails with various segfaults when openmp
threads are in use. Force the openmp thread count to 1 to avoid this
problem.
This patch is a workaround only; it is currently unknown if the root bug
lies in php-imagick or in imagemagick.
---
imagick-3.4.4+php8.0/imagick.c | 2 ++
imagick-3.4.4/imagick.c | 2 ++
2 files changed, 4 insertions(+)
diff --git a/imagick-3.4.4+php8.0/imagick.c b/imagick-3.4.4+php8.0/imagick.c
index eb65ba7..61c593c 100644
--- a/imagick-3.4.4+php8.0/imagick.c
+++ b/imagick-3.4.4+php8.0/imagick.c
@@ -3748,6 +3748,8 @@ PHP_MINIT_FUNCTION(imagick)
checkImagickVersion();
}
+ SetMagickResourceLimit(ThreadResource, 1);
+
return SUCCESS;
}
diff --git a/imagick-3.4.4/imagick.c b/imagick-3.4.4/imagick.c
index eb65ba7..61c593c 100644
--- a/imagick-3.4.4/imagick.c
+++ b/imagick-3.4.4/imagick.c
@@ -3748,6 +3748,8 @@ PHP_MINIT_FUNCTION(imagick)
checkImagickVersion();
}
+ SetMagickResourceLimit(ThreadResource, 1);
+
return SUCCESS;
}
|