From d2567bfbdf0e9fa6db0a6ed1534831ec859a3e03 Mon Sep 17 00:00:00 2001 From: davidovski Date: Wed, 15 Jun 2022 20:02:02 +0100 Subject: added deps for qemu --- repo/hunspell/CVE-2019-16707.patch | 22 ++++++++++++++++++++++ repo/hunspell/hunspell.xibuild | 37 +++++++++++++++++++++++++++++++++++++ 2 files changed, 59 insertions(+) create mode 100644 repo/hunspell/CVE-2019-16707.patch create mode 100644 repo/hunspell/hunspell.xibuild (limited to 'repo/hunspell') diff --git a/repo/hunspell/CVE-2019-16707.patch b/repo/hunspell/CVE-2019-16707.patch new file mode 100644 index 0000000..649eef5 --- /dev/null +++ b/repo/hunspell/CVE-2019-16707.patch @@ -0,0 +1,22 @@ +From ac938e2ecb48ab4dd21298126c7921689d60571b Mon Sep 17 00:00:00 2001 +From: =?UTF-8?q?Caol=C3=A1n=20McNamara?= +Date: Tue, 12 Nov 2019 20:03:15 +0000 +Subject: [PATCH] invalid read memory access #624 + +--- + src/hunspell/suggestmgr.cxx | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/src/hunspell/suggestmgr.cxx b/src/hunspell/suggestmgr.cxx +index dba084e9..c23f165a 100644 +--- a/src/hunspell/suggestmgr.cxx ++++ b/src/hunspell/suggestmgr.cxx +@@ -2040,7 +2040,7 @@ int SuggestMgr::leftcommonsubstring( + int l2 = su2.size(); + // decapitalize dictionary word + if (complexprefixes) { +- if (su1[l1 - 1] == su2[l2 - 1]) ++ if (l1 && l2 && su1[l1 - 1] == su2[l2 - 1]) + return 1; + } else { + unsigned short idx = su2.empty() ? 0 : (su2[0].h << 8) + su2[0].l; diff --git a/repo/hunspell/hunspell.xibuild b/repo/hunspell/hunspell.xibuild new file mode 100644 index 0000000..d020614 --- /dev/null +++ b/repo/hunspell/hunspell.xibuild @@ -0,0 +1,37 @@ +#!/bin/sh + +NAME="hunspell" +DESC="Spell checker and morphological analyzer library and program" + +MAKEDEPS="gettext ncurses readline autoconf automake libtool" + +PKG_VER=1.7.0 +SOURCE="https://github.com/hunspell/hunspell/archive/v$PKG_VER.tar.gz" + +ADDITIONAL=" +CVE-2019-16707.patch +" + +prepare() { + apply_patches + autoreconf -vif +} + +build() { + ./configure \ + --prefix=/usr \ + --with-ui \ + --with-readline \ + --disable-static \ + --without-included-gettext + make +} + +check() { + make check +} + +package() { + make -j1 DESTDIR="$PKG_DEST" install +} + -- cgit v1.2.1