Fix minor compil and Coverity warnings.
This commit is contained in:
parent
c16d0603c6
commit
0604d7b813
|
@ -49,7 +49,8 @@ public:
|
||||||
|
|
||||||
EE_COLLECTOR( const KICAD_T* aScanTypes = EE_COLLECTOR::AllItems ) :
|
EE_COLLECTOR( const KICAD_T* aScanTypes = EE_COLLECTOR::AllItems ) :
|
||||||
m_Unit( 0 ),
|
m_Unit( 0 ),
|
||||||
m_Convert( 0 )
|
m_Convert( 0 ),
|
||||||
|
m_ShowPinElectricalTypes( false )
|
||||||
{
|
{
|
||||||
SetScanTypes( aScanTypes );
|
SetScanTypes( aScanTypes );
|
||||||
}
|
}
|
||||||
|
|
|
@ -1886,14 +1886,14 @@ int SCH_EDIT_TOOL::ChangeTextType( const TOOL_EVENT& aEvent )
|
||||||
auto prepareForNetName =
|
auto prepareForNetName =
|
||||||
[]( wxString& aText )
|
[]( wxString& aText )
|
||||||
{
|
{
|
||||||
wxString txt = aText;
|
wxString local_txt = aText;
|
||||||
txt.Replace( "\n", "_" );
|
local_txt.Replace( "\n", "_" );
|
||||||
txt.Replace( "\r", "_" );
|
local_txt.Replace( "\r", "_" );
|
||||||
txt.Replace( "\t", "_" );
|
local_txt.Replace( "\t", "_" );
|
||||||
txt.Replace( " ", "_" );
|
local_txt.Replace( " ", "_" );
|
||||||
|
|
||||||
// label strings are "escaped" i.e. a '/' is replaced by "{slash}"
|
// label strings are "escaped" i.e. a '/' is replaced by "{slash}"
|
||||||
return EscapeString( txt, CTX_NETNAME );
|
return EscapeString( local_txt, CTX_NETNAME );
|
||||||
};
|
};
|
||||||
|
|
||||||
switch( convertTo )
|
switch( convertTo )
|
||||||
|
|
|
@ -76,7 +76,7 @@ PCB_BITMAP& PCB_BITMAP::operator=( const BOARD_ITEM& aItem )
|
||||||
delete m_image;
|
delete m_image;
|
||||||
m_image = new BITMAP_BASE( *bitmap->m_image );
|
m_image = new BITMAP_BASE( *bitmap->m_image );
|
||||||
m_pos = bitmap->m_pos;
|
m_pos = bitmap->m_pos;
|
||||||
m_image->SetPixelSizeIu( Mils2iu( 1000 ) / m_image->GetPPI() );
|
m_image->SetPixelSizeIu( (float) Mils2iu( 1000 ) / m_image->GetPPI() );
|
||||||
}
|
}
|
||||||
|
|
||||||
return *this;
|
return *this;
|
||||||
|
|
Loading…
Reference in New Issue