Fix a few minor Coverity warnings
This commit is contained in:
parent
bfa0b98b14
commit
4012aa70da
|
@ -102,7 +102,7 @@ void TransformOvalClearanceToPolygon( SHAPE_POLY_SET& aCornerBuffer,
|
|||
double delta_angle = atan2( (double)endp.y, (double)endp.x );
|
||||
int seg_len = KiROUND( EuclideanNorm( endp ) );
|
||||
|
||||
double delta = 3600 / aCircleToSegmentsCount; // rot angle in 0.1 degree
|
||||
double delta = 3600.0 / aCircleToSegmentsCount; // rot angle in 0.1 degree
|
||||
|
||||
// Compute the outlines of the segment, and creates a polygon
|
||||
// Note: the polygonal shape is built from the equivalent horizontal
|
||||
|
@ -163,7 +163,6 @@ void TransformOvalClearanceToPolygon( SHAPE_POLY_SET& aCornerBuffer,
|
|||
polyshape.Rotate( delta_angle, VECTOR2I( 0, 0 ) );
|
||||
polyshape.Move( startp );
|
||||
|
||||
|
||||
aCornerBuffer.Append( polyshape);
|
||||
}
|
||||
|
||||
|
|
|
@ -483,9 +483,6 @@ void DIALOG_CHOOSE_COMPONENT::RenderPreview( LIB_PART* aComponent, int aUnit )
|
|||
dc.SetBackground( wxBrush( bgColor.ToColour() ) );
|
||||
dc.Clear();
|
||||
|
||||
if( !aComponent )
|
||||
return;
|
||||
|
||||
int unit = aUnit > 0 ? aUnit : 1;
|
||||
int convert = m_deMorganConvert > 0 ? m_deMorganConvert : 1;
|
||||
|
||||
|
|
|
@ -45,6 +45,7 @@ public:
|
|||
m_p0 = aOther.m_p0;
|
||||
m_p1 = aOther.m_p1;
|
||||
m_pc = aOther.m_pc;
|
||||
m_width = aOther.m_width;
|
||||
}
|
||||
|
||||
~SHAPE_ARC() {};
|
||||
|
|
|
@ -67,7 +67,7 @@ class SHAPE_POLY_SET : public SHAPE
|
|||
public:
|
||||
struct TRI
|
||||
{
|
||||
TRI()
|
||||
TRI() : a(0), b(0), c(0)
|
||||
{
|
||||
}
|
||||
|
||||
|
|
|
@ -64,7 +64,7 @@ static double s_thermalRot = 450; // angle of stubs in thermal reliefs for ro
|
|||
static const bool s_DumpZonesWhenFilling = false;
|
||||
|
||||
ZONE_FILLER::ZONE_FILLER( BOARD* aBoard, COMMIT* aCommit ) :
|
||||
m_board( aBoard ), m_commit( aCommit ), m_progressReporter( nullptr )
|
||||
m_board( aBoard ), m_commit( aCommit ), m_progressReporter( nullptr ), m_count_done( 0 )
|
||||
{
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue