-
Notifications
You must be signed in to change notification settings - Fork 12
Open
Description
Platform windows.
Note that it is rare and mostly happened to me when running AOT version of our app.
Steps to reproduce:
- Do not use visual styles (don't know if that's relevant or not though)
- Show message box before creating a form
Expected result:
Message box is shown correctly
Actual result:
Rarely a .NET exception dialog is shown saying that An item with the same key has already been added.
I could not debug it locally so I don't know what is causing this (especially because it is within lock - maybe recursive call due to recursive message - I don't know). Fix is to always update the dictionary/hashtable instead of trying to add:
SolidBrush brush = new SolidBrush(color);
solidbrushes[hash] = brush; // <-- instead of Add
return brush;
Metadata
Metadata
Assignees
Labels
No labels