Fix crashes with malformed SVGs in Qt 6 Svg packages
This commit is contained in:
parent
3a2a4baf62
commit
0ff9c0527d
|
@ -0,0 +1 @@
|
||||||
|
../mingw-w64/0001-Fix-nullptr-dereference-with-invalid-SVG.patch
|
|
@ -7,7 +7,7 @@ _android_arch=aarch64
|
||||||
pkgname=android-$_android_arch-qt6-svg
|
pkgname=android-$_android_arch-qt6-svg
|
||||||
_qtver=6.6.0
|
_qtver=6.6.0
|
||||||
pkgver=${_qtver/-/}
|
pkgver=${_qtver/-/}
|
||||||
pkgrel=1
|
pkgrel=2
|
||||||
arch=(any)
|
arch=(any)
|
||||||
url='https://www.qt.io'
|
url='https://www.qt.io'
|
||||||
license=(GPL3 LGPL3 FDL custom)
|
license=(GPL3 LGPL3 FDL custom)
|
||||||
|
@ -17,8 +17,20 @@ makedepends=('android-cmake' 'qt6-base' 'ninja' 'java-environment-openjdk>=11')
|
||||||
options=('!strip' '!buildflags' 'staticlibs' '!emptydirs')
|
options=('!strip' '!buildflags' 'staticlibs' '!emptydirs')
|
||||||
groups=(android-${_android_arch}-qt6)
|
groups=(android-${_android_arch}-qt6)
|
||||||
_pkgfqn="qtsvg-everywhere-src-${_qtver}"
|
_pkgfqn="qtsvg-everywhere-src-${_qtver}"
|
||||||
source=("https://download.qt.io/official_releases/qt/${pkgver%.*}/${_qtver}/submodules/${_pkgfqn}.tar.xz")
|
source=("https://download.qt.io/official_releases/qt/${pkgver%.*}/${_qtver}/submodules/${_pkgfqn}.tar.xz"
|
||||||
sha256sums=('33da25fef51102f564624a7ea3e57cb4a0a31b7b44783d1af5749ac36d3c72de')
|
'0001-Fix-nullptr-dereference-with-invalid-SVG.patch')
|
||||||
|
sha256sums=('33da25fef51102f564624a7ea3e57cb4a0a31b7b44783d1af5749ac36d3c72de'
|
||||||
|
'83f59c72773071df6adca9c0f6f457a460bd63a4d2b85f1e0df9cabf6b1c55e9')
|
||||||
|
|
||||||
|
prepare () {
|
||||||
|
cd $_pkgfqn
|
||||||
|
|
||||||
|
# apply patches; further descriptions can be found in patch files itself
|
||||||
|
for patch in "$srcdir/"*.patch; do
|
||||||
|
msg2 "Applying patch $patch"
|
||||||
|
patch -p1 -i "$patch"
|
||||||
|
done
|
||||||
|
}
|
||||||
|
|
||||||
build() {
|
build() {
|
||||||
source android-env ${_android_arch}
|
source android-env ${_android_arch}
|
||||||
|
|
|
@ -2,7 +2,7 @@
|
||||||
\
|
\
|
||||||
_qtver=6.6.0
|
_qtver=6.6.0
|
||||||
pkgver=${_qtver/-/}
|
pkgver=${_qtver/-/}
|
||||||
pkgrel=1
|
pkgrel=2
|
||||||
arch=(any)
|
arch=(any)
|
||||||
url='https://www.qt.io'
|
url='https://www.qt.io'
|
||||||
license=(GPL3 LGPL3 FDL custom)
|
license=(GPL3 LGPL3 FDL custom)
|
||||||
|
|
|
@ -0,0 +1 @@
|
||||||
|
../mingw-w64/0001-Fix-nullptr-dereference-with-invalid-SVG.patch
|
|
@ -6,7 +6,7 @@
|
||||||
pkgname=mingw-w64-qt6-svg-static
|
pkgname=mingw-w64-qt6-svg-static
|
||||||
_qtver=6.6.0
|
_qtver=6.6.0
|
||||||
pkgver=${_qtver/-/}
|
pkgver=${_qtver/-/}
|
||||||
pkgrel=1
|
pkgrel=2
|
||||||
arch=(any)
|
arch=(any)
|
||||||
url='https://www.qt.io'
|
url='https://www.qt.io'
|
||||||
license=(GPL3 LGPL3 FDL custom)
|
license=(GPL3 LGPL3 FDL custom)
|
||||||
|
@ -16,11 +16,23 @@ makedepends=('mingw-w64-cmake-static' 'qt6-base' 'ninja')
|
||||||
options=('!strip' '!buildflags' 'staticlibs' '!emptydirs')
|
options=('!strip' '!buildflags' 'staticlibs' '!emptydirs')
|
||||||
groups=(mingw-w64-qt6)
|
groups=(mingw-w64-qt6)
|
||||||
_pkgfqn="qtsvg-everywhere-src-${_qtver}"
|
_pkgfqn="qtsvg-everywhere-src-${_qtver}"
|
||||||
source=("https://download.qt.io/official_releases/qt/${pkgver%.*}/${_qtver}/submodules/${_pkgfqn}.tar.xz")
|
source=("https://download.qt.io/official_releases/qt/${pkgver%.*}/${_qtver}/submodules/${_pkgfqn}.tar.xz"
|
||||||
sha256sums=('33da25fef51102f564624a7ea3e57cb4a0a31b7b44783d1af5749ac36d3c72de')
|
'0001-Fix-nullptr-dereference-with-invalid-SVG.patch')
|
||||||
|
sha256sums=('33da25fef51102f564624a7ea3e57cb4a0a31b7b44783d1af5749ac36d3c72de'
|
||||||
|
'83f59c72773071df6adca9c0f6f457a460bd63a4d2b85f1e0df9cabf6b1c55e9')
|
||||||
|
|
||||||
_architectures='i686-w64-mingw32 x86_64-w64-mingw32'
|
_architectures='i686-w64-mingw32 x86_64-w64-mingw32'
|
||||||
|
|
||||||
|
prepare () {
|
||||||
|
cd $_pkgfqn
|
||||||
|
|
||||||
|
# apply patches; further descriptions can be found in patch files itself
|
||||||
|
for patch in "$srcdir/"*.patch; do
|
||||||
|
msg2 "Applying patch $patch"
|
||||||
|
patch -p1 -i "$patch"
|
||||||
|
done
|
||||||
|
}
|
||||||
|
|
||||||
build() {
|
build() {
|
||||||
for _arch in ${_architectures}; do
|
for _arch in ${_architectures}; do
|
||||||
export PKG_CONFIG=/usr/bin/$_arch-pkg-config
|
export PKG_CONFIG=/usr/bin/$_arch-pkg-config
|
||||||
|
|
|
@ -0,0 +1,29 @@
|
||||||
|
From 50aaab95b65433a6a8ed616c6f473ca12389e3f0 Mon Sep 17 00:00:00 2001
|
||||||
|
From: Paul Olav Tvete <paul.tvete@qt.io>
|
||||||
|
Date: Tue, 10 Oct 2023 10:14:22 +0200
|
||||||
|
Subject: [PATCH] Fix nullptr dereference with invalid SVG
|
||||||
|
|
||||||
|
Fixes: QTBUG-117944
|
||||||
|
Pick-to: 6.6 6.5 6.2
|
||||||
|
Change-Id: I9059dc28c750fc0585f1fb982152b211c323c6cd
|
||||||
|
Reviewed-by: Eskil Abrahamsen Blomfeldt <eskil.abrahamsen-blomfeldt@qt.io>
|
||||||
|
---
|
||||||
|
src/svg/qsvghandler.cpp | 2 ++
|
||||||
|
1 file changed, 2 insertions(+)
|
||||||
|
|
||||||
|
diff --git a/src/svg/qsvghandler.cpp b/src/svg/qsvghandler.cpp
|
||||||
|
index 2649422..335500a 100644
|
||||||
|
--- a/src/svg/qsvghandler.cpp
|
||||||
|
+++ b/src/svg/qsvghandler.cpp
|
||||||
|
@@ -3606,6 +3606,8 @@ void QSvgHandler::init()
|
||||||
|
|
||||||
|
static bool detectCycles(const QSvgNode *node, QList<const QSvgUse *> active = {})
|
||||||
|
{
|
||||||
|
+ if (Q_UNLIKELY(!node))
|
||||||
|
+ return false;
|
||||||
|
switch (node->type()) {
|
||||||
|
case QSvgNode::DOC:
|
||||||
|
case QSvgNode::G:
|
||||||
|
--
|
||||||
|
2.42.0
|
||||||
|
|
|
@ -6,7 +6,7 @@
|
||||||
pkgname=mingw-w64-qt6-svg
|
pkgname=mingw-w64-qt6-svg
|
||||||
_qtver=6.6.0
|
_qtver=6.6.0
|
||||||
pkgver=${_qtver/-/}
|
pkgver=${_qtver/-/}
|
||||||
pkgrel=1
|
pkgrel=2
|
||||||
arch=(any)
|
arch=(any)
|
||||||
url='https://www.qt.io'
|
url='https://www.qt.io'
|
||||||
license=(GPL3 LGPL3 FDL custom)
|
license=(GPL3 LGPL3 FDL custom)
|
||||||
|
@ -16,11 +16,23 @@ makedepends=('mingw-w64-cmake' 'qt6-base' 'ninja')
|
||||||
options=('!strip' '!buildflags' 'staticlibs' '!emptydirs')
|
options=('!strip' '!buildflags' 'staticlibs' '!emptydirs')
|
||||||
groups=(mingw-w64-qt6)
|
groups=(mingw-w64-qt6)
|
||||||
_pkgfqn="qtsvg-everywhere-src-${_qtver}"
|
_pkgfqn="qtsvg-everywhere-src-${_qtver}"
|
||||||
source=("https://download.qt.io/official_releases/qt/${pkgver%.*}/${_qtver}/submodules/${_pkgfqn}.tar.xz")
|
source=("https://download.qt.io/official_releases/qt/${pkgver%.*}/${_qtver}/submodules/${_pkgfqn}.tar.xz"
|
||||||
sha256sums=('33da25fef51102f564624a7ea3e57cb4a0a31b7b44783d1af5749ac36d3c72de')
|
'0001-Fix-nullptr-dereference-with-invalid-SVG.patch')
|
||||||
|
sha256sums=('33da25fef51102f564624a7ea3e57cb4a0a31b7b44783d1af5749ac36d3c72de'
|
||||||
|
'83f59c72773071df6adca9c0f6f457a460bd63a4d2b85f1e0df9cabf6b1c55e9')
|
||||||
|
|
||||||
_architectures='i686-w64-mingw32 x86_64-w64-mingw32'
|
_architectures='i686-w64-mingw32 x86_64-w64-mingw32'
|
||||||
|
|
||||||
|
prepare () {
|
||||||
|
cd $_pkgfqn
|
||||||
|
|
||||||
|
# apply patches; further descriptions can be found in patch files itself
|
||||||
|
for patch in "$srcdir/"*.patch; do
|
||||||
|
msg2 "Applying patch $patch"
|
||||||
|
patch -p1 -i "$patch"
|
||||||
|
done
|
||||||
|
}
|
||||||
|
|
||||||
build() {
|
build() {
|
||||||
for _arch in ${_architectures}; do
|
for _arch in ${_architectures}; do
|
||||||
export PKG_CONFIG=/usr/bin/$_arch-pkg-config
|
export PKG_CONFIG=/usr/bin/$_arch-pkg-config
|
||||||
|
|
|
@ -2,7 +2,7 @@
|
||||||
\
|
\
|
||||||
_qtver=6.6.0
|
_qtver=6.6.0
|
||||||
pkgver=${_qtver/-/}
|
pkgver=${_qtver/-/}
|
||||||
pkgrel=1
|
pkgrel=2
|
||||||
arch=(any)
|
arch=(any)
|
||||||
url='https://www.qt.io'
|
url='https://www.qt.io'
|
||||||
license=(GPL3 LGPL3 FDL custom)
|
license=(GPL3 LGPL3 FDL custom)
|
||||||
|
|
|
@ -0,0 +1 @@
|
||||||
|
../mingw-w64/0001-Fix-nullptr-dereference-with-invalid-SVG.patch
|
|
@ -6,7 +6,7 @@
|
||||||
pkgname=static-compat-qt6-svg
|
pkgname=static-compat-qt6-svg
|
||||||
_qtver=6.6.0
|
_qtver=6.6.0
|
||||||
pkgver=${_qtver/-/}
|
pkgver=${_qtver/-/}
|
||||||
pkgrel=1
|
pkgrel=2
|
||||||
arch=(x86_64)
|
arch=(x86_64)
|
||||||
url='https://www.qt.io'
|
url='https://www.qt.io'
|
||||||
license=(GPL3 LGPL3 FDL custom)
|
license=(GPL3 LGPL3 FDL custom)
|
||||||
|
@ -15,8 +15,20 @@ depends=(static-compat-qt6-base)
|
||||||
makedepends=(static-compat-cmake ninja)
|
makedepends=(static-compat-cmake ninja)
|
||||||
options=('!strip' '!buildflags' 'staticlibs' '!emptydirs')
|
options=('!strip' '!buildflags' 'staticlibs' '!emptydirs')
|
||||||
_pkgfqn="qtsvg-everywhere-src-${_qtver}"
|
_pkgfqn="qtsvg-everywhere-src-${_qtver}"
|
||||||
source=("https://download.qt.io/official_releases/qt/${pkgver%.*}/${_qtver}/submodules/${_pkgfqn}.tar.xz")
|
source=("https://download.qt.io/official_releases/qt/${pkgver%.*}/${_qtver}/submodules/${_pkgfqn}.tar.xz"
|
||||||
sha256sums=('33da25fef51102f564624a7ea3e57cb4a0a31b7b44783d1af5749ac36d3c72de')
|
'0001-Fix-nullptr-dereference-with-invalid-SVG.patch')
|
||||||
|
sha256sums=('33da25fef51102f564624a7ea3e57cb4a0a31b7b44783d1af5749ac36d3c72de'
|
||||||
|
'83f59c72773071df6adca9c0f6f457a460bd63a4d2b85f1e0df9cabf6b1c55e9')
|
||||||
|
|
||||||
|
prepare () {
|
||||||
|
cd $_pkgfqn
|
||||||
|
|
||||||
|
# apply patches; further descriptions can be found in patch files itself
|
||||||
|
for patch in "$srcdir/"*.patch; do
|
||||||
|
msg2 "Applying patch $patch"
|
||||||
|
patch -p1 -i "$patch"
|
||||||
|
done
|
||||||
|
}
|
||||||
|
|
||||||
build() {
|
build() {
|
||||||
check_buildoption ccache y && ccache_args='
|
check_buildoption ccache y && ccache_args='
|
||||||
|
|
|
@ -2,7 +2,7 @@
|
||||||
\
|
\
|
||||||
_qtver=6.6.0
|
_qtver=6.6.0
|
||||||
pkgver=${_qtver/-/}
|
pkgver=${_qtver/-/}
|
||||||
pkgrel=1
|
pkgrel=2
|
||||||
arch=(x86_64)
|
arch=(x86_64)
|
||||||
url='https://www.qt.io'
|
url='https://www.qt.io'
|
||||||
license=(GPL3 LGPL3 FDL custom)
|
license=(GPL3 LGPL3 FDL custom)
|
||||||
|
|
Loading…
Reference in New Issue