mirror of
https://github.com/cookiengineer/audacity
synced 2025-12-09 06:06:24 +01:00
Avoid false warning about uninitialized pointer.
This commit is contained in:
committed by
James Crook
parent
48edd2298a
commit
88dfb5d7a2
@@ -238,7 +238,7 @@ static const struct Entry {
|
||||
void EditToolBar::ForAllButtons(int Action)
|
||||
{
|
||||
AudacityProject *p;
|
||||
CommandManager* cm;
|
||||
CommandManager* cm = nullptr;
|
||||
|
||||
if( Action & ETBActEnableDisable ){
|
||||
p = GetActiveProject();
|
||||
@@ -267,7 +267,7 @@ void EditToolBar::ForAllButtons(int Action)
|
||||
ToolBar::SetButtonToolTip(*mButtons[entry.tool], commands);
|
||||
}
|
||||
#endif
|
||||
if( Action & ETBActEnableDisable ){
|
||||
if (cm) {
|
||||
mButtons[entry.tool]->SetEnabled(cm->GetEnabled(entry.commandName));
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user