Skip to content

Commit

Permalink
Fix potential crash
Browse files Browse the repository at this point in the history
  • Loading branch information
nyalldawson committed Aug 26, 2016
1 parent 979e1a2 commit 8b62500
Showing 1 changed file with 5 additions and 2 deletions.
7 changes: 5 additions & 2 deletions src/core/qgsvectorlayer.cpp
Expand Up @@ -2177,8 +2177,11 @@ bool QgsVectorLayer::writeStyle( QDomNode &node, QDomDocument &doc, QString &err

if ( hasGeometryType() )
{
QDomElement rendererElement = mRendererV2->save( doc );
node.appendChild( rendererElement );
if ( mRendererV2 )
{
QDomElement rendererElement = mRendererV2->save( doc );
node.appendChild( rendererElement );
}

if ( mLabeling )
{
Expand Down

0 comments on commit 8b62500

Please sign in to comment.