Skip to content
Permalink
Browse files

Merge pull request #3196 from nirvn/fix_right_click

[bugfix] fix crash when right-clicking on geometryless layers
  • Loading branch information
nyalldawson committed Jun 12, 2016
2 parents f1ec121 + 054604b commit 1d6dfc5aedd57e73ea412ee57ed2c17b291bc9b8
Showing with 1 addition and 1 deletion.
  1. +1 −1 src/app/qgsapplayertreeviewmenuprovider.cpp
@@ -148,7 +148,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 1d6dfc5

Please sign in to comment.
You can’t perform that action at this time.