aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMarian Buschsieweke <marian.buschsieweke@ovgu.de>2020-06-11 10:18:40 +0200
committerRasmus Thomsen <oss@cogitri.dev>2020-06-11 11:32:53 +0000
commit89aac2088f22ee651dc64dee386f306c1e36ac04 (patch)
tree4e05c8997144776f33d1fa50831b21c912537b2b
parent309418aa8e74c3008222fd08fdfd84751af75d9d (diff)
main/pango: Fix segfault with gtk+2.0
-rw-r--r--main/pango/APKBUILD6
-rw-r--r--main/pango/fix-gtk+2.0.patch29
2 files changed, 33 insertions, 2 deletions
diff --git a/main/pango/APKBUILD b/main/pango/APKBUILD
index bdd551e007d..21e46d3ef0a 100644
--- a/main/pango/APKBUILD
+++ b/main/pango/APKBUILD
@@ -3,7 +3,7 @@
# Maintainer: Rasmus Thomsen <oss@cogitri.dev>
pkgname=pango
pkgver=1.45.1
-pkgrel=0
+pkgrel=1
pkgdesc="A library for layout and rendering of text"
url="https://www.pango.org/"
arch="all"
@@ -18,6 +18,7 @@ triggers="$pkgname.trigger=/usr/lib/pango/*/modules"
subpackages="$pkgname-dev $pkgname-doc $pkgname-tools"
source="https://download.gnome.org/sources/pango/${pkgver%.*}/pango-$pkgver.tar.xz
disable-layout-test.patch
+ fix-gtk+2.0.patch
"
# secfixes:
@@ -49,4 +50,5 @@ tools() {
}
sha512sums="33d255257bf88a0dd71457454cb91b97f9873fff5e0ed49ca710a6b37e7b74b93ad065c28d7ad6c62fe75dabd11d34a6fc889482674dcf9cf6ffb90c60b2808a pango-1.45.1.tar.xz
-811f94a5bd60abc038ff78cd08dd9fb69218ba9afc8568b1a545032ee6173935966d85d90c6b4b18370daa5106df26427810cea1be57e37d3ef141624949a241 disable-layout-test.patch"
+811f94a5bd60abc038ff78cd08dd9fb69218ba9afc8568b1a545032ee6173935966d85d90c6b4b18370daa5106df26427810cea1be57e37d3ef141624949a241 disable-layout-test.patch
+a5355e3c0d58eb260cd158089262e0f3e128a80342d296cbc65a882016d0fc7c428b0597a36c446673e899257fed40e3cd5a240dfcf7cc896df87eaefa96ea2b fix-gtk+2.0.patch"
diff --git a/main/pango/fix-gtk+2.0.patch b/main/pango/fix-gtk+2.0.patch
new file mode 100644
index 00000000000..e8c5ccea9d9
--- /dev/null
+++ b/main/pango/fix-gtk+2.0.patch
@@ -0,0 +1,29 @@
+Backport of https://gitlab.gnome.org/GNOME/pango/-/commit/89ca7a4299b873746e3b6c1e1260ee8430b63fd4
+From 89ca7a4299b873746e3b6c1e1260ee8430b63fd4 Mon Sep 17 00:00:00 2001
+From: Matthias Clasen <mclasen@redhat.com>
+Date: Wed, 10 Jun 2020 09:41:03 -0400
+Subject: [PATCH] Fix a crash in gtk2
+
+Apparently, gtk2 assumes that calling pango_layout_set_attributes
+guarantees that the attribute list gains a ref.
+
+Fixes: #479
+---
+ pango/pango-layout.c | 5 -----
+ 1 file changed, 5 deletions(-)
+
+diff --git a/pango/pango-layout.c b/pango/pango-layout.c
+--- a/pango/pango-layout.c
++++ b/pango/pango-layout.c
+@@ -689,11 +689,6 @@
+ if (!attrs && !layout->attrs)
+ return;
+
+- /* Also both empty */
+- if (!_pango_attr_list_has_attributes (layout->attrs) &&
+- !_pango_attr_list_has_attributes (attrs))
+- return;
+-
+ old_attrs = layout->attrs;
+
+ /* We always clear lines such that this function can be called