Skip to content
Permalink
Browse files
fix infinite loop in qgsstyle
  • Loading branch information
PeterPetrik authored and github-actions committed Jul 2, 2021
1 parent fa1a59f commit a233ff6bb7ae5f478910470fdde7e6767768451b
Showing with 6 additions and 0 deletions.
  1. +6 −0 src/core/symbology/qgsstyle.cpp
@@ -2755,6 +2755,7 @@ bool QgsStyle::importXml( const QString &filename, int sinceVersion )
if ( entityAddedVersion != 0 && sinceVersion != -1 && entityAddedVersion <= sinceVersion )
{
// skip the symbol, should already be present
e = e.nextSiblingElement();
continue;
}

@@ -2810,6 +2811,7 @@ bool QgsStyle::importXml( const QString &filename, int sinceVersion )
if ( entityAddedVersion != 0 && sinceVersion != -1 && entityAddedVersion <= sinceVersion )
{
// skip the ramp, should already be present
e = e.nextSiblingElement();
continue;
}

@@ -2859,6 +2861,7 @@ bool QgsStyle::importXml( const QString &filename, int sinceVersion )
if ( entityAddedVersion != 0 && sinceVersion != -1 && entityAddedVersion <= sinceVersion )
{
// skip the format, should already be present
e = e.nextSiblingElement();
continue;
}

@@ -2904,6 +2907,7 @@ bool QgsStyle::importXml( const QString &filename, int sinceVersion )
if ( entityAddedVersion != 0 && sinceVersion != -1 && entityAddedVersion <= sinceVersion )
{
// skip the settings, should already be present
e = e.nextSiblingElement();
continue;
}

@@ -2950,6 +2954,7 @@ bool QgsStyle::importXml( const QString &filename, int sinceVersion )
if ( entityAddedVersion != 0 && sinceVersion != -1 && entityAddedVersion <= sinceVersion )
{
// skip the shape, should already be present
e = e.nextSiblingElement();
continue;
}

@@ -2995,6 +3000,7 @@ bool QgsStyle::importXml( const QString &filename, int sinceVersion )
if ( entityAddedVersion != 0 && sinceVersion != -1 && entityAddedVersion <= sinceVersion )
{
// skip the symbol, should already be present
e = e.nextSiblingElement();
continue;
}

0 comments on commit a233ff6

Please sign in to comment.