Package: release.debian.org Severity: normal User: release.debian....@packages.debian.org Usertags: unblock
-----BEGIN PGP SIGNED MESSAGE----- Hash: SHA512 Dear release team, I've backported an upstream fix in sonnet for stretch that I consider worthwhile, the corresponding debian/changelog entry is: * Pick "Fix segfault in trigrams generation and expose MAXGRAMS constant in the header" (c7f0b14) Add upstream patch as: Fix-segfault-in-trigrams-generation-and-expose-MAXGRAMS-c.patch Also, I've updated the sonnet-plugins package description to fix #801728. I've uploaded 5.28.0-2 with these changes, and it has already built in all the release architectures. I'm attaching the corresponding debdiff. Happy hacking, Please unblock package sonnet unblock sonnet/5.28.0-2 - -- System Information: Debian Release: 9.0 APT prefers unstable-debug APT policy: (500, 'unstable-debug'), (500, 'testing-debug'), (500, 'testing'), (500, 'stable'), (50, 'unstable'), (1, 'experimental') Architecture: amd64 (x86_64) Foreign Architectures: i386, armhf Kernel: Linux 4.9.0-2-amd64 (SMP w/4 CPU cores) Locale: LANG=en_GB.UTF-8, LC_CTYPE=en_GB.UTF-8 (charmap=UTF-8) Shell: /bin/sh linked to /bin/bash Init: systemd (via /run/systemd/system) -----BEGIN PGP SIGNATURE----- iQJEBAEBCgAuFiEE+JIdOnQEyG4RNSIVxxl2mbKbIyoFAljqSqcQHG1heHlAZGVi aWFuLm9yZwAKCRDHGXaZspsjKmt6D/9zSKVHAsWmcf98TeXDrAsu66v54MSw2mlU fpdY9sTOHlnjBJ7WCwZFzvUiHlt0m5XEMPos9Pn/TxEGEf6L1rrb2e3MaJyrdRJF DIndiAKiX/2AJhPRmeWwGGMjoLBpzLIVEUvvQq+eBZT7WHQ5KDuPekdGTbxui2+t 5a9UjKam6OzlSZ5WN2vPDdUoyoVkK1Z0krAq5Yqn9G0JbrFeT9/8dGVA/x8hv5zR TMpBWYWkx4Edq0DUBC3+wv/IPa7Kr0fnNfctFyWlvt9f3rLDxJHPqHWrAIyrSGTT XdyHA7/9//r9Z3JLCdl86XS8zauRnAuzpKxZR2yaUk3OoKSwGmaqMCKK0G+g3glG Pb+XmRrzd6gjglrBW13Y8H/bLXZnba/nHFXC0Xs1Gj52xFp3YQbEsSQ5uoSvFbfW lc+BLVDWjNkw9PANkEswZIBQS4eSx5E8VN4TbWsBjtwMsDfECNBWMPkKIPjpbtq7 QXTq97PU6wUnlJXrVKHyShV/jfrkNOpAQmOZZWVnoOR6OB66m1MU3CbmPbTdpaH4 kdalp/5z67bNtAsE/KlLhD6g8+E4juz9az530NUjgxfANCGYYE5FtRxXYk3G31WU Yas9Edf6Ns3qmZyeXWlRLshIxQ8Iquuuftg14NbM+gl2ugnWr0HTQflNfWxaG/8S D+msZu0QzQ== =Aiwz -----END PGP SIGNATURE-----
diff -Nru sonnet-5.28.0/debian/changelog sonnet-5.28.0/debian/changelog --- sonnet-5.28.0/debian/changelog 2016-11-18 16:03:17.000000000 +0100 +++ sonnet-5.28.0/debian/changelog 2017-04-09 11:32:31.000000000 +0200 @@ -1,3 +1,13 @@ +sonnet (5.28.0-2) unstable; urgency=medium + + * Update the sonnet-plugins package description (Closes: 801728) + * Pick "Fix segfault in trigrams generation and expose MAXGRAMS constant in + the header" (c7f0b14) + Add upstream patch as: + Fix-segfault-in-trigrams-generation-and-expose-MAXGRAMS-c.patch + + -- Maximiliano Curia <m...@debian.org> Sun, 09 Apr 2017 11:32:31 +0200 + sonnet (5.28.0-1) unstable; urgency=medium [ Automatic packaging ] diff -Nru sonnet-5.28.0/debian/control sonnet-5.28.0/debian/control --- sonnet-5.28.0/debian/control 2016-11-18 16:03:17.000000000 +0100 +++ sonnet-5.28.0/debian/control 2017-04-09 11:32:31.000000000 +0200 @@ -104,5 +104,6 @@ checking using various plugin based backends. It is part of KDE Frameworks 5. . - This package provides plugins used by Sonnet to interact with - the various spell checking backends. + This package provides plugins used by Sonnet to interact with the following + spell checking backends: aspell, hunspell or hspell. The dictionaries need to + be installed separatedly. diff -Nru sonnet-5.28.0/debian/patches/Fix-segfault-in-trigrams-generation-and-expose-MAXGRAMS-c.patch sonnet-5.28.0/debian/patches/Fix-segfault-in-trigrams-generation-and-expose-MAXGRAMS-c.patch --- sonnet-5.28.0/debian/patches/Fix-segfault-in-trigrams-generation-and-expose-MAXGRAMS-c.patch 1970-01-01 01:00:00.000000000 +0100 +++ sonnet-5.28.0/debian/patches/Fix-segfault-in-trigrams-generation-and-expose-MAXGRAMS-c.patch 2017-04-09 11:32:31.000000000 +0200 @@ -0,0 +1,78 @@ +From: John Salatas <jsala...@gmail.com> +Date: Wed, 18 Jan 2017 13:51:56 -0800 +Subject: Fix segfault in trigrams generation and expose MAXGRAMS constant in + the header + +Differential Revision: https://phabricator.kde.org/D4181 +--- + data/CMakeLists.txt | 2 +- + data/gentrigrams.cpp | 6 +++--- + src/core/guesslanguage.cpp | 3 --- + src/core/guesslanguage.h | 3 +++ + 4 files changed, 7 insertions(+), 7 deletions(-) + +diff --git a/data/CMakeLists.txt b/data/CMakeLists.txt +index 716a09f..d65cff7 100644 +--- a/data/CMakeLists.txt ++++ b/data/CMakeLists.txt +@@ -10,7 +10,7 @@ ecm_mark_nongui_executable(parsetrigrams) + ecm_mark_nongui_executable(gentrigrams) + + TARGET_LINK_LIBRARIES(parsetrigrams PUBLIC Qt5::Core) +-TARGET_LINK_LIBRARIES(gentrigrams PUBLIC Qt5::Core) ++TARGET_LINK_LIBRARIES(gentrigrams PUBLIC Qt5::Core KF5::SonnetCore) + INSTALL(TARGETS parsetrigrams EXPORT KF5SonnetTargets ${KF5_INSTALL_TARGETS_DEFAULT_ARGS}) + INSTALL(TARGETS gentrigrams EXPORT KF5SonnetTargets ${KF5_INSTALL_TARGETS_DEFAULT_ARGS}) + +diff --git a/data/gentrigrams.cpp b/data/gentrigrams.cpp +index 7dd7755..6badbfa 100644 +--- a/data/gentrigrams.cpp ++++ b/data/gentrigrams.cpp +@@ -25,6 +25,7 @@ + #include <QtCore/QHash> + #include <QtCore/QString> + #include <QtCore/QDebug> ++#include "guesslanguage.h" + + int main(int argc, char *argv[]) + { +@@ -75,9 +76,8 @@ int main(int argc, char *argv[]) + + qDebug() << "Weeding out..."; + QMap<int, QString>::iterator i = orderedTrigrams.begin(); +- while (orderedTrigrams.size() > 300) { +- orderedTrigrams.erase(i); +- i++; ++ while (orderedTrigrams.size() > Sonnet::MAXGRAMS) { ++ i = orderedTrigrams.erase(i); + } + qDebug() << "Weeded!"; + +diff --git a/src/core/guesslanguage.cpp b/src/core/guesslanguage.cpp +index 546c514..723ad96 100644 +--- a/src/core/guesslanguage.cpp ++++ b/src/core/guesslanguage.cpp +@@ -61,9 +61,6 @@ az-Latn az + namespace Sonnet + { + +-// Amount of trigrams in each file +-static const int MAXGRAMS = 300; +- + class GuessLanguagePrivate + { + public: +diff --git a/src/core/guesslanguage.h b/src/core/guesslanguage.h +index e1bb609..2f224b8 100644 +--- a/src/core/guesslanguage.h ++++ b/src/core/guesslanguage.h +@@ -28,6 +28,9 @@ + namespace Sonnet + { + ++// Amount of trigrams in each file ++static const int MAXGRAMS = 300; ++ + class GuessLanguagePrivate; + + /** diff -Nru sonnet-5.28.0/debian/patches/series sonnet-5.28.0/debian/patches/series --- sonnet-5.28.0/debian/patches/series 1970-01-01 01:00:00.000000000 +0100 +++ sonnet-5.28.0/debian/patches/series 2017-04-09 11:32:31.000000000 +0200 @@ -0,0 +1 @@ +Fix-segfault-in-trigrams-generation-and-expose-MAXGRAMS-c.patch