hi... KConfigGroup parent() currently always returns a KConfigGroup object with a dptr. isValid() determines validity based on having a dptr. this leads to loops like this:
KConfigGroup group = <some valid group>;
while (group.isValid()) {
group = group.parent();
}
to never terminate, as parent() returns the top level group forever (name =
"<default>"). this is because, due to the behavior of parent(), the top level
group is its own parent.
is it intended that the parent of the default group is itself?
this would not be so much of a problem is there was a way to test for the
group being the top level group without hardcoding magic literal strings like
"<default>" into the code.
--
Aaron J. Seigo
signature.asc
Description: This is a digitally signed message part.
