From 993c446fdfb2faadc31894d88091251db897195f Mon Sep 17 00:00:00 2001 From: jean-pierre charras Date: Mon, 25 Jul 2022 13:07:57 +0200 Subject: [PATCH] Fix some warnings detected by PVS-STUDIO (most are not used vars) --- 3d-viewer/3d_rendering/opengl/render_3d_opengl.cpp | 2 +- common/config_params.cpp | 2 +- common/dialogs/dialog_page_settings.cpp | 2 -- common/eda_base_frame.cpp | 4 ---- common/filename_resolver.cpp | 2 -- common/font/font.cpp | 1 - common/plotters/GERBER_plotter.cpp | 1 - common/plotters/PS_plotter.cpp | 1 - common/plotters/SVG_plotter.cpp | 1 - common/project/net_settings.cpp | 1 - common/settings/settings_manager.cpp | 2 -- common/tool/tool_manager.cpp | 2 -- common/widgets/net_selector.cpp | 1 - common/widgets/unit_binder.cpp | 3 +-- eeschema/connection_graph.cpp | 2 -- eeschema/dialogs/dialog_erc.cpp | 1 - eeschema/dialogs/dialog_netlist.cpp | 2 -- eeschema/dialogs/dialog_sheet_properties.cpp | 1 - eeschema/dialogs/dialog_sim_settings.cpp | 2 -- eeschema/dialogs/dialog_symbol_properties.cpp | 3 --- eeschema/erc.cpp | 4 ---- eeschema/sch_edit_frame.cpp | 1 - eeschema/sch_line.cpp | 2 +- eeschema/sch_plugins/kicad/sch_sexpr_parser.cpp | 5 ----- eeschema/sch_plugins/kicad/sch_sexpr_plugin.cpp | 5 ----- eeschema/sch_sheet.cpp | 1 - eeschema/sch_symbol.cpp | 3 --- eeschema/sch_text.cpp | 2 -- eeschema/symbol_editor/symbol_editor.cpp | 2 -- eeschema/symbol_editor/symbol_editor_import_export.cpp | 2 +- eeschema/symbol_library.cpp | 2 -- eeschema/tools/backannotate.cpp | 1 - eeschema/tools/ee_selection_tool.cpp | 1 - eeschema/tools/symbol_editor_control.cpp | 3 --- 34 files changed, 5 insertions(+), 65 deletions(-) diff --git a/3d-viewer/3d_rendering/opengl/render_3d_opengl.cpp b/3d-viewer/3d_rendering/opengl/render_3d_opengl.cpp index 12c3518fe8..47dc36a498 100644 --- a/3d-viewer/3d_rendering/opengl/render_3d_opengl.cpp +++ b/3d-viewer/3d_rendering/opengl/render_3d_opengl.cpp @@ -1051,7 +1051,7 @@ void RENDER_3D_OPENGL::freeAllLists() m_triangles.clear(); - for( const std::pair& entry : m_3dModelMap ) + for( const std::pair& entry : m_3dModelMap ) delete entry.second; m_3dModelMap.clear(); diff --git a/common/config_params.cpp b/common/config_params.cpp index fcf02e5a3c..b963c8dea4 100644 --- a/common/config_params.cpp +++ b/common/config_params.cpp @@ -423,7 +423,7 @@ void PARAM_CFG_WXSTRING_SET::SaveParam( wxConfigBase* aConfig ) const for( const wxString& str : *m_Pt_param ) { - wxString key, data; + wxString key; key = m_Ident; key << i++; diff --git a/common/dialogs/dialog_page_settings.cpp b/common/dialogs/dialog_page_settings.cpp index 78cd661a0a..633ae70945 100644 --- a/common/dialogs/dialog_page_settings.cpp +++ b/common/dialogs/dialog_page_settings.cpp @@ -126,8 +126,6 @@ DIALOG_PAGES_SETTINGS::~DIALOG_PAGES_SETTINGS() bool DIALOG_PAGES_SETTINGS::TransferDataToWindow() { - wxString msg; - // initialize page format choice box and page format list. // The first shows translated strings, the second contains not translated strings m_paperSizeComboBox->Clear(); diff --git a/common/eda_base_frame.cpp b/common/eda_base_frame.cpp index 4462c12ab0..a2dffb4949 100644 --- a/common/eda_base_frame.cpp +++ b/common/eda_base_frame.cpp @@ -709,13 +709,9 @@ void EDA_BASE_FRAME::LoadWindowSettings( const WINDOW_SETTINGS* aCfg ) void EDA_BASE_FRAME::SaveWindowSettings( WINDOW_SETTINGS* aCfg ) { - wxString text; - if( IsIconized() ) return; - wxString baseCfgName = ConfigBaseName(); - // If the window is maximized, we use the saved window size from before it was maximized if( IsMaximized() ) { diff --git a/common/filename_resolver.cpp b/common/filename_resolver.cpp index b0bc877e8a..c146fd9fbd 100644 --- a/common/filename_resolver.cpp +++ b/common/filename_resolver.cpp @@ -161,8 +161,6 @@ bool FILENAME_RESOLVER::createPathList() if( !m_paths.empty() ) return true; - wxString kmod; - // add an entry for the default search path; at this point // we cannot set a sensible default so we use an empty string. // the user may change this later with a call to SetProjectDir() diff --git a/common/font/font.cpp b/common/font/font.cpp index 35b6c2ae42..5985cba864 100644 --- a/common/font/font.cpp +++ b/common/font/font.cpp @@ -373,7 +373,6 @@ void wordbreakMarkup( std::vector>* aWords, } else { - wxString space( wxS( " " ) ); wxString textRun = aNode->asWxString(); wxArrayString words; diff --git a/common/plotters/GERBER_plotter.cpp b/common/plotters/GERBER_plotter.cpp index d1c7d1c798..72dc6aa154 100644 --- a/common/plotters/GERBER_plotter.cpp +++ b/common/plotters/GERBER_plotter.cpp @@ -317,7 +317,6 @@ bool GERBER_PLOTTER::StartPlot() bool GERBER_PLOTTER::EndPlot() { char line[1024]; - wxString msg; wxASSERT( m_outputFile ); diff --git a/common/plotters/PS_plotter.cpp b/common/plotters/PS_plotter.cpp index f3961035ce..d8dbe10561 100644 --- a/common/plotters/PS_plotter.cpp +++ b/common/plotters/PS_plotter.cpp @@ -765,7 +765,6 @@ void PS_PLOTTER::PenTo( const VECTOR2I& pos, char plume ) bool PS_PLOTTER::StartPlot() { wxASSERT( m_outputFile ); - wxString msg; static const char* PSMacro[] = { diff --git a/common/plotters/SVG_plotter.cpp b/common/plotters/SVG_plotter.cpp index 6ab574ae72..756c076bca 100644 --- a/common/plotters/SVG_plotter.cpp +++ b/common/plotters/SVG_plotter.cpp @@ -714,7 +714,6 @@ void SVG_PLOTTER::PenTo( const VECTOR2I& pos, char plume ) bool SVG_PLOTTER::StartPlot() { wxASSERT( m_outputFile ); - wxString msg; static const char* header[] = { diff --git a/common/project/net_settings.cpp b/common/project/net_settings.cpp index 79f884d0c1..55c410525c 100644 --- a/common/project/net_settings.cpp +++ b/common/project/net_settings.cpp @@ -455,7 +455,6 @@ bool NET_SETTINGS::ParseBusGroup( const wxString& aGroup, wxString* aName, size_t groupLen = aGroup.length(); size_t i = 0; wxString prefix; - wxString suffix; wxString tmp; int braceNesting = 0; diff --git a/common/settings/settings_manager.cpp b/common/settings/settings_manager.cpp index 8ccf4d3770..1f9d6b490a 100644 --- a/common/settings/settings_manager.cpp +++ b/common/settings/settings_manager.cpp @@ -1120,8 +1120,6 @@ bool SETTINGS_MANAGER::BackupProject( REPORTER& aReporter ) const target.SetName( fileName ); target.SetExt( ArchiveFileExtension ); - wxDir dir( target.GetPath() ); - if( !target.DirExists() && !wxMkdir( target.GetPath() ) ) { wxLogTrace( traceSettings, wxT( "Could not create project backup path %s" ), target.GetPath() ); diff --git a/common/tool/tool_manager.cpp b/common/tool/tool_manager.cpp index 2762ef99da..241535249c 100644 --- a/common/tool/tool_manager.cpp +++ b/common/tool/tool_manager.cpp @@ -823,8 +823,6 @@ bool TOOL_MANAGER::dispatchActivation( const TOOL_EVENT& aEvent ) if( aEvent.IsActivate() ) { - wxString cmdStr( *aEvent.GetCommandStr() ); - auto tool = m_toolNameIndex.find( *aEvent.GetCommandStr() ); if( tool != m_toolNameIndex.end() ) diff --git a/common/widgets/net_selector.cpp b/common/widgets/net_selector.cpp index fcf806a20f..8416b9b910 100644 --- a/common/widgets/net_selector.cpp +++ b/common/widgets/net_selector.cpp @@ -201,7 +201,6 @@ public: wxString escapedNetName; wxString remainingName; int selection = m_listBox->GetSelection(); - wxString prefix = CREATE_NET; if( selection >= 0 ) selectedNetName = m_listBox->GetString( (unsigned) selection ); diff --git a/common/widgets/unit_binder.cpp b/common/widgets/unit_binder.cpp index 79138a32fc..19fda7ecbc 100644 --- a/common/widgets/unit_binder.cpp +++ b/common/widgets/unit_binder.cpp @@ -188,14 +188,13 @@ void UNIT_BINDER::onKillFocus( wxFocusEvent& aEvent ) if( m_eval.Process( textEntry->GetValue() ) ) { textEntry->GetSelection( &m_selStart, &m_selEnd ); - wxString sel = textEntry->GetStringSelection(); - textEntry->ChangeValue( m_eval.Result() ); #ifdef __WXGTK__ // Manually copy the selected text to the primary selection clipboard if( wxTheClipboard->Open() ) { + wxString sel = textEntry->GetStringSelection(); bool clipTarget = wxTheClipboard->IsUsingPrimarySelection(); wxTheClipboard->UsePrimarySelection( true ); wxTheClipboard->SetData( new wxTextDataObject( sel ) ); diff --git a/eeschema/connection_graph.cpp b/eeschema/connection_graph.cpp index 98d108be3d..2498671d0a 100644 --- a/eeschema/connection_graph.cpp +++ b/eeschema/connection_graph.cpp @@ -2419,7 +2419,6 @@ bool CONNECTION_GRAPH::ercCheckBusToNetConflicts( const CONNECTION_SUBGRAPH* aSu bool CONNECTION_GRAPH::ercCheckBusToBusConflicts( const CONNECTION_SUBGRAPH* aSubgraph ) { - wxString msg; const SCH_SHEET_PATH& sheet = aSubgraph->m_sheet; SCH_SCREEN* screen = sheet.LastScreen(); @@ -2587,7 +2586,6 @@ bool CONNECTION_GRAPH::ercCheckBusToBusEntryConflicts( const CONNECTION_SUBGRAPH bool CONNECTION_GRAPH::ercCheckNoConnects( const CONNECTION_SUBGRAPH* aSubgraph ) { ERC_SETTINGS& settings = m_schematic->ErcSettings(); - wxString msg; const SCH_SHEET_PATH& sheet = aSubgraph->m_sheet; SCH_SCREEN* screen = sheet.LastScreen(); bool ok = true; diff --git a/eeschema/dialogs/dialog_erc.cpp b/eeschema/dialogs/dialog_erc.cpp index bf0d6744ae..0d46a3a0f5 100644 --- a/eeschema/dialogs/dialog_erc.cpp +++ b/eeschema/dialogs/dialog_erc.cpp @@ -613,7 +613,6 @@ void DIALOG_ERC::OnERCItemRClick( wxDataViewEvent& aEvent ) std::shared_ptr rcItem = node->m_RcItem; wxString listName; wxMenu menu; - wxString msg; switch( settings.GetSeverity( rcItem->GetErrorCode() ) ) { diff --git a/eeschema/dialogs/dialog_netlist.cpp b/eeschema/dialogs/dialog_netlist.cpp index b132194ee2..2db2c32e1e 100644 --- a/eeschema/dialogs/dialog_netlist.cpp +++ b/eeschema/dialogs/dialog_netlist.cpp @@ -552,8 +552,6 @@ bool NETLIST_DIALOG::FilenamePrms( NETLIST_TYPE_ID aType, wxString * aExt, wxStr void NETLIST_DIALOG::WriteCurrentNetlistSetup() { - wxString msg; - NetlistUpdateOpt(); EESCHEMA_SETTINGS* cfg = dynamic_cast( Kiface().KifaceSettings() ); diff --git a/eeschema/dialogs/dialog_sheet_properties.cpp b/eeschema/dialogs/dialog_sheet_properties.cpp index 726a9fc062..9a373abe5f 100644 --- a/eeschema/dialogs/dialog_sheet_properties.cpp +++ b/eeschema/dialogs/dialog_sheet_properties.cpp @@ -183,7 +183,6 @@ bool DIALOG_SHEET_PROPERTIES::TransferDataToWindow() bool DIALOG_SHEET_PROPERTIES::Validate() { - wxString msg; LIB_ID id; if( !m_grid->CommitPendingChanges() || !m_grid->Validate() ) diff --git a/eeschema/dialogs/dialog_sim_settings.cpp b/eeschema/dialogs/dialog_sim_settings.cpp index df4a080894..fbdd297a99 100644 --- a/eeschema/dialogs/dialog_sim_settings.cpp +++ b/eeschema/dialogs/dialog_sim_settings.cpp @@ -275,8 +275,6 @@ bool DIALOG_SIM_SETTINGS::TransferDataFromWindow() } else { - wxString extendedMsg; - if( m_simCommand.IsEmpty() ) { KIDIALOG dlg( this, _( "No valid simulation is configured." ), _( "Warning" ), diff --git a/eeschema/dialogs/dialog_symbol_properties.cpp b/eeschema/dialogs/dialog_symbol_properties.cpp index ded61d3f41..ef85620c71 100644 --- a/eeschema/dialogs/dialog_symbol_properties.cpp +++ b/eeschema/dialogs/dialog_symbol_properties.cpp @@ -578,7 +578,6 @@ void DIALOG_SYMBOL_PROPERTIES::OnCancelButtonClick( wxCommandEvent& event ) bool DIALOG_SYMBOL_PROPERTIES::Validate() { - wxString msg; LIB_ID id; if( !m_fieldsGrid->CommitPendingChanges() || !m_fieldsGrid->Validate() ) @@ -635,8 +634,6 @@ bool DIALOG_SYMBOL_PROPERTIES::TransferDataFromWindow() // the schematic file. currentScreen->Remove( m_symbol ); - wxString msg; - // save old cmp in undo list if not already in edit, or moving ... if( m_symbol->GetEditFlags() == 0 ) GetParent()->SaveCopyInUndoList( currentScreen, m_symbol, UNDO_REDO::CHANGED, false ); diff --git a/eeschema/erc.cpp b/eeschema/erc.cpp index 2783462a16..102c2f01b0 100644 --- a/eeschema/erc.cpp +++ b/eeschema/erc.cpp @@ -339,7 +339,6 @@ int ERC_TESTER::TestMultiunitFootprints() SCH_SHEET_LIST sheets = m_schematic->GetSheets(); int errors = 0; - std::map footprints; SCH_MULTI_UNIT_REFERENCE_MAP refMap; sheets.GetMultiUnitSymbols( refMap, true ); @@ -589,7 +588,6 @@ int ERC_TESTER::TestMultUnitPinConflicts() for( const std::pair> net : nets ) { const wxString& netName = net.first.first; - std::vector pins; for( CONNECTION_SUBGRAPH* subgraph : net.second ) { @@ -647,8 +645,6 @@ int ERC_TESTER::TestSimilarLabels() for( const std::pair> net : nets ) { - std::vector pins; - for( CONNECTION_SUBGRAPH* subgraph : net.second ) { for( EDA_ITEM* item : subgraph->m_items ) diff --git a/eeschema/sch_edit_frame.cpp b/eeschema/sch_edit_frame.cpp index 9c9ecdddd6..eac8bc978b 100644 --- a/eeschema/sch_edit_frame.cpp +++ b/eeschema/sch_edit_frame.cpp @@ -1832,7 +1832,6 @@ void SCH_EDIT_FRAME::onSize( wxSizeEvent& aEvent ) void SCH_EDIT_FRAME::SaveSymbolToSchematic( const LIB_SYMBOL& aSymbol, const KIID& aSchematicSymbolUUID ) { - wxString msg; bool appendToUndo = false; SCH_SHEET_PATH sheetPath; diff --git a/eeschema/sch_line.cpp b/eeschema/sch_line.cpp index b7f78e6211..2afbfef765 100644 --- a/eeschema/sch_line.cpp +++ b/eeschema/sch_line.cpp @@ -736,7 +736,7 @@ void SCH_LINE::GetSelectedPoints( std::vector& aPoints ) const wxString SCH_LINE::GetSelectMenuText( EDA_UNITS aUnits ) const { - wxString txtfmt, orient; + wxString txtfmt; if( m_start.x == m_end.x ) { diff --git a/eeschema/sch_plugins/kicad/sch_sexpr_parser.cpp b/eeschema/sch_plugins/kicad/sch_sexpr_parser.cpp index 21cf2b9261..885cc435d6 100644 --- a/eeschema/sch_plugins/kicad/sch_sexpr_parser.cpp +++ b/eeschema/sch_plugins/kicad/sch_sexpr_parser.cpp @@ -701,8 +701,6 @@ void SCH_SEXPR_PARSER::parsePinNames( std::unique_ptr& aSymbol ) wxCHECK_RET( CurTok() == T_pin_names, "Cannot parse " + GetTokenString( CurTok() ) + " as a pin_name token." ); - wxString error; - T token = NextTok(); if( token == T_LEFT ) @@ -736,7 +734,6 @@ LIB_FIELD* SCH_SEXPR_PARSER::parseProperty( std::unique_ptr& aSymbol wxT( "Cannot parse " ) + GetTokenString( CurTok() ) + wxT( " as a property." ) ); wxCHECK( aSymbol, nullptr ); - wxString error; wxString name; wxString value; std::unique_ptr field = std::make_unique( aSymbol.get(), @@ -1567,7 +1564,6 @@ LIB_TEXT* SCH_SEXPR_PARSER::parseText() wxT( "Cannot parse " ) + GetTokenString( CurTok() ) + wxT( " as a text token." ) ); T token; - wxString tmp; std::unique_ptr text = std::make_unique( nullptr ); text->SetUnit( m_unit ); @@ -2423,7 +2419,6 @@ SCH_SYMBOL* SCH_SEXPR_PARSER::parseSchematicSymbol() wxT( "Cannot parse " ) + GetTokenString( CurTok() ) + wxT( " as a symbol." ) ); T token; - wxString tmp; wxString libName; SCH_FIELD* field; std::unique_ptr symbol = std::make_unique(); diff --git a/eeschema/sch_plugins/kicad/sch_sexpr_plugin.cpp b/eeschema/sch_plugins/kicad/sch_sexpr_plugin.cpp index 06c7e86457..36a5e271bc 100644 --- a/eeschema/sch_plugins/kicad/sch_sexpr_plugin.cpp +++ b/eeschema/sch_plugins/kicad/sch_sexpr_plugin.cpp @@ -628,9 +628,6 @@ void SCH_SEXPR_PLUGIN::saveSymbol( SCH_SYMBOL* aSymbol, SCH_SHEET_PATH* aSheetPa wxCHECK_RET( aSymbol != nullptr && m_out != nullptr, "" ); std::string libName; - wxArrayString reference_fields; - - static wxString delimiters( wxT( " " ) ); wxString symbol_name = aSymbol->GetLibId().Format(); @@ -988,8 +985,6 @@ void SCH_SEXPR_PLUGIN::saveShape( SCH_SHAPE* aShape, int aNestLevel ) { wxCHECK_RET( aShape != nullptr && m_out != nullptr, "" ); - wxString lineType; - switch( aShape->GetShape() ) { case SHAPE_T::ARC: diff --git a/eeschema/sch_sheet.cpp b/eeschema/sch_sheet.cpp index a9a65bf9b6..0cf530c0b8 100644 --- a/eeschema/sch_sheet.cpp +++ b/eeschema/sch_sheet.cpp @@ -1034,7 +1034,6 @@ void SCH_SHEET::Plot( PLOTTER* aPlotter, bool aBackground ) const if( aBackground && !aPlotter->GetColorMode() ) return; - wxString msg; VECTOR2I pos; auto* settings = dynamic_cast( aPlotter->RenderSettings() ); bool override = settings ? settings->m_OverrideItemColors : false; diff --git a/eeschema/sch_symbol.cpp b/eeschema/sch_symbol.cpp index 43a0047ef1..d47defe16a 100644 --- a/eeschema/sch_symbol.cpp +++ b/eeschema/sch_symbol.cpp @@ -812,7 +812,6 @@ void SCH_SYMBOL::UpdateFields( const SCH_SHEET_PATH* aPath, bool aUpdateStyle, b { if( m_part ) { - wxString symbolName; std::vector fields; m_part->GetFields( fields ); @@ -1125,8 +1124,6 @@ bool SCH_SYMBOL::AddSheetPathReferenceEntryIfMissing( const KIID_PATH& aSheetPat // a empty sheet path is illegal: wxCHECK( aSheetPath.size() > 0, false ); - wxString reference_path; - for( const SYMBOL_INSTANCE_REFERENCE& instance : m_instanceReferences ) { // if aSheetPath is found, nothing to do: diff --git a/eeschema/sch_text.cpp b/eeschema/sch_text.cpp index fba6a60f16..da928ce47d 100644 --- a/eeschema/sch_text.cpp +++ b/eeschema/sch_text.cpp @@ -426,8 +426,6 @@ void SCH_TEXT::Plot( PLOTTER* aPlotter, bool aBackground ) const if( aBackground ) return; - static std::vector s_poly; - RENDER_SETTINGS* settings = aPlotter->RenderSettings(); SCH_CONNECTION* connection = Connection(); int layer = ( connection && connection->IsBus() ) ? LAYER_BUS : m_layer; diff --git a/eeschema/symbol_editor/symbol_editor.cpp b/eeschema/symbol_editor/symbol_editor.cpp index 6cf1ce9678..ef957f8b04 100644 --- a/eeschema/symbol_editor/symbol_editor.cpp +++ b/eeschema/symbol_editor/symbol_editor.cpp @@ -58,7 +58,6 @@ SYMBOL_SAVEAS_TYPE SYMBOL_LEGACYFILEDLG_SAVE_AS::m_option = SYMBOL_SAVEAS_TYPE:: void SYMBOL_EDIT_FRAME::updateTitle() { - wxString lib = GetCurLib(); wxString title; if( GetCurSymbol() && IsSymbolFromSchematic() ) @@ -299,7 +298,6 @@ bool SYMBOL_EDIT_FRAME::LoadSymbolFromCurrentLib( const wxString& aAliasName, in bool SYMBOL_EDIT_FRAME::LoadOneLibrarySymbolAux( LIB_SYMBOL* aEntry, const wxString& aLibrary, int aUnit, int aConvert ) { - wxString msg, rootName; bool rebuildMenuAndToolbar = false; if( !aEntry || aLibrary.empty() ) diff --git a/eeschema/symbol_editor/symbol_editor_import_export.cpp b/eeschema/symbol_editor/symbol_editor_import_export.cpp index 490a21f91a..1eaa803770 100644 --- a/eeschema/symbol_editor/symbol_editor_import_export.cpp +++ b/eeschema/symbol_editor/symbol_editor_import_export.cpp @@ -113,7 +113,7 @@ void SYMBOL_EDIT_FRAME::ImportSymbol() void SYMBOL_EDIT_FRAME::ExportSymbol() { - wxString msg, title; + wxString msg; LIB_SYMBOL* symbol = getTargetSymbol(); if( !symbol ) diff --git a/eeschema/symbol_library.cpp b/eeschema/symbol_library.cpp index 2d89185bcb..40e7fc98af 100644 --- a/eeschema/symbol_library.cpp +++ b/eeschema/symbol_library.cpp @@ -477,8 +477,6 @@ void SYMBOL_LIBS::LoadAllLibraries( PROJECT* aProject, bool aShowProgress ) lib_dialog.Show(); } - wxString progress_message; - for( unsigned i = 0; i < lib_names.GetCount(); ++i ) { if( aShowProgress ) diff --git a/eeschema/tools/backannotate.cpp b/eeschema/tools/backannotate.cpp index db2cf79719..59a7728f97 100644 --- a/eeschema/tools/backannotate.cpp +++ b/eeschema/tools/backannotate.cpp @@ -66,7 +66,6 @@ bool BACK_ANNOTATE::BackAnnotateSymbols( const std::string& aNetlist ) { m_changesCount = 0; m_appendUndo = false; - wxString msg; if( !m_matchByReference && !m_processValues && !m_processFootprints && !m_processReferences && !m_processNetNames ) diff --git a/eeschema/tools/ee_selection_tool.cpp b/eeschema/tools/ee_selection_tool.cpp index d40fff2b5d..e49bbd5998 100644 --- a/eeschema/tools/ee_selection_tool.cpp +++ b/eeschema/tools/ee_selection_tool.cpp @@ -1477,7 +1477,6 @@ int EE_SELECTION_TOOL::SelectConnection( const TOOL_EVENT& aEvent ) return 0; SCH_LINE* line = (SCH_LINE*) m_selection.Front(); - EDA_ITEMS items; unsigned done = false; m_frame->GetScreen()->ClearDrawingState(); diff --git a/eeschema/tools/symbol_editor_control.cpp b/eeschema/tools/symbol_editor_control.cpp index 042b49c4b4..8197199f13 100644 --- a/eeschema/tools/symbol_editor_control.cpp +++ b/eeschema/tools/symbol_editor_control.cpp @@ -518,8 +518,6 @@ int SYMBOL_EDITOR_CONTROL::ExportView( const TOOL_EVENT& aEvent ) return 0; } - wxString file_ext = wxT( "png" ); - wxString mask = wxT( "*." ) + file_ext; wxFileName fn( symbol->GetName() ); fn.SetExt( "png" ); @@ -558,7 +556,6 @@ int SYMBOL_EDITOR_CONTROL::ExportSymbolAsSVG( const TOOL_EVENT& aEvent ) return 0; } - wxString file_ext = SVGFileExtension; wxFileName fn( symbol->GetName() ); fn.SetExt( SVGFileExtension );