Skip to content

Potential fixes for 4 code quality findings#3702

Draft
ann0see wants to merge 4 commits into
mainfrom
ai-findings-autofix/src-clientdlg.cpp
Draft

Potential fixes for 4 code quality findings#3702
ann0see wants to merge 4 commits into
mainfrom
ai-findings-autofix/src-clientdlg.cpp

Conversation

@ann0see
Copy link
Copy Markdown
Member

@ann0see ann0see commented May 20, 2026

This PR applies 4/4 suggestions from code quality AI findings.

Only for review. We should then decide if we actually have a memory leak here.

ann0see and others added 4 commits May 20, 2026 20:24
Co-authored-by: Copilot Autofix powered by AI <223894421+github-code-quality[bot]@users.noreply.github.com>
Co-authored-by: Copilot Autofix powered by AI <223894421+github-code-quality[bot]@users.noreply.github.com>
Co-authored-by: Copilot Autofix powered by AI <223894421+github-code-quality[bot]@users.noreply.github.com>
Co-authored-by: Copilot Autofix powered by AI <223894421+github-code-quality[bot]@users.noreply.github.com>
@ann0see
Copy link
Copy Markdown
Member Author

ann0see commented May 20, 2026

I don't think everything here is valid.

Comment thread src/clientdlg.cpp
Comment on lines +859 to +861
QSoundEffect sf;
sf.setSource ( QUrl::fromLocalFile ( ":sounds/res/sounds/new_message.wav" ) );
sf.play();
Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This may be valid. Stack vs heap allocation?

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

-> memory leak

Comment thread src/clientdlg.cpp
Comment on lines 1449 to 1458
case MT_BAR_NARROW:
lbrInputLevelL->SetLevelMeterType ( CLevelMeter::MT_BAR_WIDE );
lbrInputLevelR->SetLevelMeterType ( CLevelMeter::MT_BAR_WIDE );
lbrInputLevelL->SetLevelMeterType ( CLevelMeter::MT_BAR_NARROW );
lbrInputLevelR->SetLevelMeterType ( CLevelMeter::MT_BAR_NARROW );
break;

case MT_LED_ROUND_SMALL:
lbrInputLevelL->SetLevelMeterType ( CLevelMeter::MT_LED_ROUND_BIG );
lbrInputLevelR->SetLevelMeterType ( CLevelMeter::MT_LED_ROUND_BIG );
lbrInputLevelL->SetLevelMeterType ( CLevelMeter::MT_LED_ROUND_SMALL );
lbrInputLevelR->SetLevelMeterType ( CLevelMeter::MT_LED_ROUND_SMALL );
break;
}
Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Unsure about those.

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@ann0see ann0see requested review from pljones and softins May 20, 2026 18:56
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant