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

Fix for issue#5171 #5175

Merged
merged 1 commit into from
Jul 5, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -351,11 +351,6 @@ public TChannel CreateChannel<TChannel>(EndpointAddress address, Uri via)
}

serviceChannel.ClientRuntime.GetRuntime().InitializeChannel(clientChannel);
OperationContext current = OperationContext.Current;
if ((current != null) && (current.InstanceContext != null))
{
current.InstanceContext.WmiChannels.Add((IChannel)serviceChannel.Proxy);
}

return (TChannel)serviceChannel.Proxy;
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,6 @@ public sealed class InstanceContext : CommunicationObject, IExtensibleObject<Ins
private SynchronizationContext _synchronizationContext;
private object _userObject;
private bool _wellKnown;
private SynchronizedCollection<IChannel> _wmiChannels;
private bool _isUserCreated;

public InstanceContext(object implementation)
Expand Down Expand Up @@ -149,24 +148,6 @@ internal object UserObject
get { return _userObject; }
}

internal ICollection<IChannel> WmiChannels
{
get
{
if (_wmiChannels == null)
{
lock (ThisLock)
{
if (_wmiChannels == null)
{
_wmiChannels = new SynchronizedCollection<IChannel>();
}
}
}
return _wmiChannels;
}
}

protected override void OnAbort()
{
_channels.Abort();
Expand Down