Index: kdecore/config/kconfig.cpp
===================================================================
--- kdecore/config/kconfig.cpp	(wersja 799330)
+++ kdecore/config/kconfig.cpp	(kopia robocza)
@@ -121,8 +121,8 @@
     const int len = source.length();
     const bool sameName = (destination == source);
 
-    foreach (const KEntryKey& key, entryMap.keys()) {
-        const QByteArray& group = key.mGroup;
+    for (KEntryMap::ConstIterator entryMapIt( entryMap.constBegin() ); entryMapIt != entryMap.constEnd(); ++entryMapIt) {
+        const QByteArray& group = entryMapIt.key().mGroup;
 
         if (!group.startsWith(source)) // nothing to do
             continue;
@@ -131,12 +131,12 @@
         if (group.length() > len && group[len] != '\x1d')
             continue;
 
-        KEntryKey newKey = key;
+        KEntryKey newKey = entryMapIt.key();
 
         if (!sameName)
             newKey.mGroup.replace(0, len, destination);
 
-        KEntry entry = entryMap[key];
+        KEntry entry = entryMap[ entryMapIt.key() ];
         entry.bDirty = true;
         otherMap[newKey] = entry;
     }
@@ -198,10 +198,10 @@
     Q_D(const KConfig);
     QStringList groups;
 
-    foreach (const KEntryKey& key, d->entryMap.keys())
-        if (key.mKey.isNull() && !key.mGroup.isEmpty() &&
-            key.mGroup != "<default>" && key.mGroup != "$Version")
-            groups << QString::fromUtf8(key.mGroup);
+    for (KEntryMap::ConstIterator entryMapIt( d->entryMap.constBegin() ); entryMapIt != d->entryMap.constEnd(); ++entryMapIt)
+        if (entryMapIt.key().mKey.isNull() && !entryMapIt.key().mGroup.isEmpty() &&
+            entryMapIt.key().mGroup != "<default>" && entryMapIt.key().mGroup != "$Version")
+            groups << QString::fromUtf8(entryMapIt.key().mGroup);
 
     return groups;
 }
@@ -211,10 +211,10 @@
     QByteArray theGroup = group + '\x1d';
     QSet<QString> groups;
 
-    foreach (const KEntryKey& key, entryMap.keys())
-        if (key.mKey.isNull() && key.mGroup.startsWith(theGroup))
+    for (KEntryMap::ConstIterator entryMapIt( entryMap.constBegin() ); entryMapIt != entryMap.constEnd(); ++entryMapIt)
+        if (entryMapIt.key().mKey.isNull() && entryMapIt.key().mGroup.startsWith(theGroup))
         {
-            QString groupname = QString::fromUtf8(key.mGroup.mid(theGroup.length()));
+            QString groupname = QString::fromUtf8(entryMapIt.key().mGroup.mid(theGroup.length()));
             groups << groupname.left(groupname.indexOf('\x1d'));
         }
 
@@ -626,9 +626,9 @@
     QSet<QByteArray> groups;
     groups << aGroup;
 
-    foreach (const KEntryKey& key, d->entryMap.keys()) {
-        if (key.mKey.isNull() && key.mGroup.startsWith(theGroup)) {
-            groups << key.mGroup;
+    for (KEntryMap::ConstIterator entryMapIt( d->entryMap.constBegin() ); entryMapIt != d->entryMap.constEnd(); ++entryMapIt) {
+        if (entryMapIt.key().mKey.isNull() && entryMapIt.key().mGroup.startsWith(theGroup)) {
+            groups << entryMapIt.key().mGroup;
         }
     }
 
