Skip to content

Commit

Permalink
fix warnings
Browse files Browse the repository at this point in the history
  • Loading branch information
jef-n committed Oct 6, 2013
1 parent 6b99d0d commit feefffd
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
2 changes: 1 addition & 1 deletion src/core/composer/qgscomposition.cpp
Expand Up @@ -963,7 +963,7 @@ void QgsComposition::selectNextByZOrder( ZValueDirection direction )
}

//select item with target z value
QgsComposerItem* selectedItem;
QgsComposerItem* selectedItem = 0;
switch ( direction )
{
case QgsComposition::ZValueBelow:
Expand Down
6 changes: 3 additions & 3 deletions src/core/qgsvectorlayereditutils.cpp
Expand Up @@ -352,7 +352,7 @@ int QgsVectorLayerEditUtils::splitParts( const QList<QgsPoint>& splitLine, bool
featureList << QgsFeature( f );
}

int addPartRet;
int addPartRet = 0;
foreach ( const QgsFeature& feat, featureList )
{
QList<QgsGeometry*> newGeometries;
Expand All @@ -364,14 +364,14 @@ int QgsVectorLayerEditUtils::splitParts( const QList<QgsPoint>& splitLine, bool
for ( int i = 0; i < newGeometries.size(); ++i )
{
addPartRet = feat.geometry()->addPart( newGeometries.at( i ) );
if ( addPartRet != 0 )
if ( addPartRet )
break;
}

// For test only: Exception already thrown here...
// feat.geometry()->asWkb();

if ( addPartRet == 0 )
if ( !addPartRet )
{
L->editBuffer()->changeGeometry( feat.id(), feat.geometry() );
}
Expand Down

0 comments on commit feefffd

Please sign in to comment.