Skip to content
Permalink
Browse files
fix crash when right-clicking on geometryless layers
(cherry picked from commit 054604b)
  • Loading branch information
nirvn authored and jef-n committed Jul 7, 2016
1 parent 0fc21a8 commit c2fe26053351c21ae4dca939065a4145e328b42f
Showing with 1 addition and 1 deletion.
  1. +1 −1 src/app/qgsapplayertreeviewmenuprovider.cpp
@@ -130,7 +130,7 @@ QMenu* QgsAppLayerTreeViewMenuProvider::createContextMenu()
if ( vlayer )
{
const QgsSingleSymbolRendererV2* singleRenderer = dynamic_cast< const QgsSingleSymbolRendererV2* >( vlayer->rendererV2() );
if ( !singleRenderer && vlayer->rendererV2()->embeddedRenderer() )
if ( !singleRenderer && vlayer->rendererV2() && vlayer->rendererV2()->embeddedRenderer() )
{
singleRenderer = dynamic_cast< const QgsSingleSymbolRendererV2* >( vlayer->rendererV2()->embeddedRenderer() );
}

0 comments on commit c2fe260

Please sign in to comment.