Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[release/8.0] Avoid Creating Graphics in TabControl.WmReflectDrawItem() #12216

Merged
merged 1 commit into from
Oct 2, 2024

Conversation

lonitra
Copy link
Member

@lonitra lonitra commented Sep 24, 2024

Backport of #10536, fixes #12157

Customer Impact

We are leaking a Graphics object causing the finalizer to run to dispose it, which is sub optimal. Users can also see a OutOfMemoryException surface from this.

Testing

Manual verification that leak is not present

Risk

Low. The change involves avoid creating a new Graphics object here, which is unnecessary

Microsoft Reviewers: Open in CodeFlow

@lonitra lonitra requested a review from a team as a code owner September 24, 2024 18:56
@lonitra lonitra changed the title [release/8.0] dispose graphics in TabControl.WmReflectDrawItem() [release/8.0] Avoid Creating Graphics in TabControl.WmReflectDrawItem() Sep 24, 2024
@lonitra lonitra added 🚫 * NO-MERGE * The PR is not ready for merge yet (see discussion for detailed reasons) Servicing-consider .NET Shiproom label indicating a PR seeks to enter into a branch under Tell-Mode criteria Servicing-approved .NET Shiproom approved the PR for merge and removed Servicing-consider .NET Shiproom label indicating a PR seeks to enter into a branch under Tell-Mode criteria labels Sep 24, 2024
@lonitra
Copy link
Member Author

lonitra commented Sep 24, 2024

No merge until servicing branch opens

@lonitra lonitra removed the 🚫 * NO-MERGE * The PR is not ready for merge yet (see discussion for detailed reasons) label Oct 2, 2024
@lonitra lonitra merged commit 34d50ce into dotnet:release/8.0 Oct 2, 2024
9 checks passed
@lonitra lonitra deleted the backport10724 branch October 2, 2024 16:12
@github-actions github-actions bot locked and limited conversation to collaborators Nov 2, 2024
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Servicing-approved .NET Shiproom approved the PR for merge
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants