Skip to content

Commit

Permalink
remaining cppcheck issues
Browse files Browse the repository at this point in the history
  • Loading branch information
jef-n committed Feb 7, 2015
1 parent 2589b1a commit 6ed695a
Show file tree
Hide file tree
Showing 10 changed files with 23 additions and 10 deletions.
5 changes: 3 additions & 2 deletions src/plugins/globe/osgEarthUtil/Controls.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1801,18 +1801,19 @@ ControlNodeBin::draw( const ControlContext& context, bool newContext, int bin )

if ( _sortingEnabled && _sortByDistance )
{
for( ControlNodeCollection::iterator i = _controlNodes.begin(); i != _controlNodes.end(); ++i )
for( ControlNodeCollection::iterator i = _controlNodes.begin(); i != _controlNodes.end(); )
{
ControlNode* node = i->second.get();
if ( node->getNumParents() == 0 )
{
_renderNodes.erase( node );
_controlNodes.erase( i );
_controlNodes.erase( i++ );
}
else
{
ControlNode::PerViewData& nodeData = node->getData( context._view );
byDepth.insert( ControlNodePair(nodeData._screenPos.z(), node) );
++i;
}
}

Expand Down
3 changes: 3 additions & 0 deletions tests/src/core/testqgsatlascomposition.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -44,6 +44,9 @@ class TestQgsAtlasComposition : public QObject
, mLabel2( 0 )
, mAtlasMap( 0 )
, mOverview( 0 )
, mVectorLayer( 0 )
, mVectorLayer2( 0 )
, mAtlas( 0 )
{}

private slots:
Expand Down
3 changes: 2 additions & 1 deletion tests/src/core/testqgsdiagram.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,8 @@ class TestQgsDiagram : public QObject

public:
TestQgsDiagram()
: mPointsLayer( 0 )
: mTestHasError( false )
, mPointsLayer( 0 )
, mComposition( 0 )
, mPieDiagram( 0 )
, mComposerMap( 0 )
Expand Down
3 changes: 2 additions & 1 deletion tests/src/core/testqgsdiagramexpression.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,8 @@ class TestQgsDiagramExpression : public QObject
Q_OBJECT
public:
TestQgsDiagramExpression()
: mMapSettings( 0 )
: mTestHasError( false )
, mMapSettings( 0 )
, mPointsLayer( 0 )
, mComposition( 0 )
, mPieDiagram( 0 )
Expand Down
3 changes: 2 additions & 1 deletion tests/src/core/testqgsgradients.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,8 @@ class TestQgsGradients : public QObject

public:
TestQgsGradients()
: mpPolysLayer( 0 )
: mTestHasError( false )
, mpPolysLayer( 0 )
, mGradientFill( 0 )
, mFillSymbol( 0 )
, mSymbolRenderer( 0 )
Expand Down
3 changes: 2 additions & 1 deletion tests/src/core/testqgsrasterfill.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,8 @@ class TestQgsRasterFill : public QObject

public:
TestQgsRasterFill()
: mpPolysLayer( 0 )
: mTestHasError( false )
, mpPolysLayer( 0 )
, mRasterFill( 0 )
, mFillSymbol( 0 )
, mSymbolRenderer( 0 )
Expand Down
3 changes: 2 additions & 1 deletion tests/src/core/testqgsrenderers.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,8 @@ class TestQgsRenderers : public QObject

public:
TestQgsRenderers()
: mpPointsLayer( 0 )
: mTestHasError( false )
, mpPointsLayer( 0 )
, mpLinesLayer( 0 )
, mpPolysLayer( 0 )
{}
Expand Down
3 changes: 2 additions & 1 deletion tests/src/core/testqgsshapeburst.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,8 @@ class TestQgsShapeburst : public QObject
Q_OBJECT
public:
TestQgsShapeburst()
: mpPolysLayer()
: mTestHasError( false )
, mpPolysLayer()
, mShapeburstFill( 0 )
, mFillSymbol( 0 )
, mSymbolRenderer( 0 )
Expand Down
3 changes: 2 additions & 1 deletion tests/src/core/testqgsvectorlayer.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -72,7 +72,8 @@ class TestQgsVectorLayer : public QObject
Q_OBJECT
public:
TestQgsVectorLayer()
: mpMapRenderer( 0 )
: mTestHasError( false )
, mpMapRenderer( 0 )
, mpPointsLayer( 0 )
, mpLinesLayer( 0 )
, mpPolysLayer( 0 )
Expand Down
4 changes: 3 additions & 1 deletion tests/src/gui/testqgsrasterhistogram.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -38,10 +38,12 @@
/** \ingroup UnitTests
* This is a unit test to verify that raster histogram works
*/
class TestRasterHistogram: public QObject
class TestRasterHistogram : public QObject
{
Q_OBJECT

TestRasterHistogram() {}

private:

QString mDataDir;
Expand Down

0 comments on commit 6ed695a

Please sign in to comment.