diff options
author | Andreas Sturmlechner <asturm@gentoo.org> | 2017-02-18 23:44:27 +0100 |
---|---|---|
committer | Andreas Sturmlechner <asturm@gentoo.org> | 2017-02-19 00:33:10 +0100 |
commit | 3542c10ba95fb072f50711f53a0b60bbde63b540 (patch) | |
tree | d8417f82a7e6f61af0a607c44921a45604f1ac19 /media-gfx/digikam/files/digikam-5.3.0-redeyes-crash.patch | |
parent | media-sound/ifp-gnome: python-single-r1, EAPI=6 (diff) | |
download | gentoo-3542c10ba95fb072f50711f53a0b60bbde63b540.tar.gz gentoo-3542c10ba95fb072f50711f53a0b60bbde63b540.tar.bz2 gentoo-3542c10ba95fb072f50711f53a0b60bbde63b540.zip |
media-gfx/digikam: Fix crash on fixing red eyes
Gentoo-bug: 609216
Thanks-to: Oliver Schwabedissen <Oliver@Schwabedissen.name>
Package-Manager: portage-2.3.3
Diffstat (limited to 'media-gfx/digikam/files/digikam-5.3.0-redeyes-crash.patch')
-rw-r--r-- | media-gfx/digikam/files/digikam-5.3.0-redeyes-crash.patch | 43 |
1 files changed, 43 insertions, 0 deletions
diff --git a/media-gfx/digikam/files/digikam-5.3.0-redeyes-crash.patch b/media-gfx/digikam/files/digikam-5.3.0-redeyes-crash.patch new file mode 100644 index 000000000000..055f9be3acd1 --- /dev/null +++ b/media-gfx/digikam/files/digikam-5.3.0-redeyes-crash.patch @@ -0,0 +1,43 @@ +commit 1dad795deb0fbfcef5ad4932f7ade781d35ce17e +Author: Maik Qualmann <metzpinguin@gmail.com> +Date: Wed Nov 23 19:37:46 2016 +0100 + + fix not found shapepredictor.dat file + BUGS: 372831 + FIXED-IN: 5.4.0 + +diff --git a/libs/dimg/filters/redeye/redeyecorrectionfilter.cpp b/libs/dimg/filters/redeye/redeyecorrectionfilter.cpp +index 1cbaefc..a834208 100644 +--- a/libs/dimg/filters/redeye/redeyecorrectionfilter.cpp ++++ b/libs/dimg/filters/redeye/redeyecorrectionfilter.cpp +@@ -99,14 +99,14 @@ RedEyeCorrectionFilter::~RedEyeCorrectionFilter() + + void RedEyeCorrectionFilter::filterImage() + { +- if (d->sp == 0) ++ if (!d->sp) + { + // Loading the shape predictor model + +- QList<QString> path = QStandardPaths::locateAll(QStandardPaths::GenericDataLocation, +- QString::fromLatin1("digikam/facesengine"), +- QStandardPaths::LocateDirectory); +- QFile model(*path.begin() + QLatin1String("/ShapePredictor.dat")); ++ QString path = QStandardPaths::locate(QStandardPaths::GenericDataLocation, ++ QLatin1String("digikam/facesengine/shapepredictor.dat")); ++ ++ QFile model(path); + + if (model.open(QIODevice::ReadOnly)) + { +@@ -116,6 +116,10 @@ void RedEyeCorrectionFilter::filterImage() + dataStream >> *temp; + d->sp = temp; + } ++ else ++ { ++ return; ++ } + } + + cv::Mat intermediateImage; |