Skip to content

Commit

Permalink
Fix #10657 (crash opening a project with invalid join)
Browse files Browse the repository at this point in the history
  • Loading branch information
wonder-sk committed Jun 20, 2014
1 parent 9d90923 commit c1c8aa6
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions src/core/qgsvectorlayerjoinbuffer.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -69,6 +69,9 @@ void QgsVectorLayerJoinBuffer::cacheJoinLayer( QgsVectorJoinInfo& joinInfo )
else
joinFieldIndex = cacheLayer->pendingFields().indexFromName( joinInfo.joinFieldName );

if ( joinFieldIndex < 0 || joinFieldIndex >= cacheLayer->pendingFields().count() )
return;

joinInfo.cachedAttributes.clear();

QgsFeatureIterator fit = cacheLayer->getFeatures( QgsFeatureRequest().setFlags( QgsFeatureRequest::NoGeometry ) );
Expand Down

0 comments on commit c1c8aa6

Please sign in to comment.