[prev in list] [next in list] [prev in thread] [next in thread] 

List:       kde-commits
Subject:    [krecipes] src/dialogs/recipeinput: Fix hang when editing some recipes.
From:       José_Manuel_Santamaría_Lema <panfaust () gmail ! com>
Date:       2016-03-29 17:38:21
Message-ID: E1akxav-000214-Ge () scm ! kde ! org
[Download RAW message or body]

Git commit 7b0ef2699058d5769d0409253cbbe4ae02a73763 by José Manuel Santamaría Lema.
Committed on 29/03/2016 at 07:21.
Pushed by joselema into branch 'master'.

Fix hang when editing some recipes.

M  +2    -2    src/dialogs/recipeinput/nutrientinfodetailsdialog.cpp

http://commits.kde.org/krecipes/7b0ef2699058d5769d0409253cbbe4ae02a73763

diff --git a/src/dialogs/recipeinput/nutrientinfodetailsdialog.cpp \
b/src/dialogs/recipeinput/nutrientinfodetailsdialog.cpp index b14fd35..5c1ffa9 100644
--- a/src/dialogs/recipeinput/nutrientinfodetailsdialog.cpp
+++ b/src/dialogs/recipeinput/nutrientinfodetailsdialog.cpp
@@ -187,8 +187,8 @@ NutrientInfo::Status \
NutrientInfoDetailsDialog::checkIngredientStatus(  QSet< \
QPair<RecipeDB::IdType,RecipeDB::IdType> > usedUnitIds;  \
QPair<RecipeDB::IdType,RecipeDB::IdType> usedPair;  QStringList missingConversions;
-				WeightList::const_iterator weight_it = weights.constBegin();
-				while ( weight_it != weights.constEnd() ) {
+				WeightList::const_iterator weight_it;
+				for ( weight_it = weights.constEnd(); weight_it != weights.constEnd(); \
++weight_it ) {  //skip entries that only differ in how it's prepared
 					usedPair.first = weight_it->perAmountUnitId();
 					usedPair.second = weight_it->weightUnitId();


[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic