Update EventMap.Registry.HasHandler to use .Equals
This fixes internal TFS issue #1161343 The event handlers being tracked by EventMap may not be reference equal, so use .Equals to compare them instead of ==. This fixes an event handler leak and matches the equals behavior from before commit 7cda9431, when we used List.Remove. This change also adds some more careful null handling for when a Registry<TEventHandler> has a null handler.
Showing
想要评论请 注册 或 登录