Skip to content

Commit 55f87af

Browse files
committed
Revert "fixes zeromq#829"
This reverts commit d4da358.
1 parent d4da358 commit 55f87af

File tree

3 files changed

+6
-11
lines changed

3 files changed

+6
-11
lines changed

src/NetMQ.sln.DotSettings

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -8,9 +8,6 @@
88
<s:String x:Key="/Default/CodeStyle/Naming/CSharpNaming/PredefinedNamingRules/=PrivateInstanceFields/@EntryIndexedValue">&lt;Policy Inspect="True" Prefix="m_" Suffix="" Style="aaBb" /&gt;</s:String>
99
<s:String x:Key="/Default/CodeStyle/Naming/CSharpNaming/PredefinedNamingRules/=PrivateStaticFields/@EntryIndexedValue">&lt;Policy Inspect="True" Prefix="s_" Suffix="" Style="aaBb" /&gt;</s:String>
1010
<s:String x:Key="/Default/CodeStyle/Naming/CSharpNaming/PredefinedNamingRules/=PrivateStaticReadonly/@EntryIndexedValue">&lt;Policy Inspect="True" Prefix="s_" Suffix="" Style="aaBb" /&gt;</s:String>
11-
<s:Boolean x:Key="/Default/Environment/SettingsMigration/IsMigratorApplied/=JetBrains_002EReSharper_002EPsi_002ECSharp_002ECodeStyle_002ECSharpKeepExistingMigration/@EntryIndexedValue">True</s:Boolean>
12-
<s:Boolean x:Key="/Default/Environment/SettingsMigration/IsMigratorApplied/=JetBrains_002EReSharper_002EPsi_002ECSharp_002ECodeStyle_002ECSharpPlaceEmbeddedOnSameLineMigration/@EntryIndexedValue">True</s:Boolean>
13-
<s:Boolean x:Key="/Default/Environment/SettingsMigration/IsMigratorApplied/=JetBrains_002EReSharper_002EPsi_002ECSharp_002ECodeStyle_002ECSharpUseContinuousIndentInsideBracesMigration/@EntryIndexedValue">True</s:Boolean>
1411
<s:Boolean x:Key="/Default/Environment/SettingsMigration/IsMigratorApplied/=JetBrains_002EReSharper_002EPsi_002ECSharp_002ECodeStyle_002ESettingsUpgrade_002EAddAccessorOwnerDeclarationBracesMigration/@EntryIndexedValue">True</s:Boolean>
1512
<s:Boolean x:Key="/Default/Environment/SettingsMigration/IsMigratorApplied/=JetBrains_002EReSharper_002EPsi_002ECSharp_002ECodeStyle_002ESettingsUpgrade_002EMigrateBlankLinesAroundFieldToBlankLinesAroundProperty/@EntryIndexedValue">True</s:Boolean>
1613
<s:Boolean x:Key="/Default/Environment/SettingsMigration/IsMigratorApplied/=JetBrains_002EReSharper_002EPsi_002ECSharp_002ECodeStyle_002ESettingsUpgrade_002EMigrateThisQualifierSettings/@EntryIndexedValue">True</s:Boolean>

src/NetMQ/ISocketPollableCollection.cs

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,3 @@
1-
using System;
21
using JetBrains.Annotations;
32
using NetMQ.Monitoring;
43

@@ -14,6 +13,5 @@ public interface ISocketPollableCollection
1413
{
1514
void Add([NotNull] ISocketPollable socket);
1615
void Remove([NotNull] ISocketPollable socket);
17-
void RemoveAndDispose<T>(T socket) where T : ISocketPollable, IDisposable;
1816
}
1917
}

src/NetMQ/Monitoring/NetMQMonitor.cs

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@ public class NetMQMonitor : IDisposable
2424
{
2525
[NotNull] private readonly NetMQSocket m_monitoringSocket;
2626
private readonly bool m_ownsMonitoringSocket;
27-
[CanBeNull] private ISocketPollableCollection m_attachedPoller;
27+
[CanBeNull] private NetMQPoller m_attachedPoller;
2828
private int m_cancel;
2929

3030
private readonly ManualResetEvent m_isStoppedEvent = new ManualResetEvent(true);
@@ -208,15 +208,15 @@ private void InternalClose()
208208
m_monitoringSocket.Disconnect(Endpoint);
209209
}
210210
catch (Exception)
211-
{ }
211+
{}
212212
finally
213213
{
214214
IsRunning = false;
215215
m_isStoppedEvent.Set();
216216
}
217217
}
218218

219-
public void AttachToPoller<T>(T poller) where T : ISocketPollableCollection
219+
public void AttachToPoller([NotNull] NetMQPoller poller)
220220
{
221221
if (poller == null)
222222
throw new ArgumentNullException(nameof(poller));
@@ -233,12 +233,12 @@ public void DetachFromPoller()
233233
{
234234
DetachFromPoller(false);
235235
}
236-
236+
237237
private void DetachFromPoller(bool dispose)
238238
{
239239
if (m_attachedPoller == null)
240240
throw new InvalidOperationException("Not attached to a poller");
241-
241+
242242
if (dispose)
243243
m_attachedPoller.RemoveAndDispose(m_monitoringSocket);
244244
else
@@ -324,7 +324,7 @@ protected virtual void Dispose(bool disposing)
324324
if (!disposing)
325325
return;
326326

327-
bool attachedToPoller = m_attachedPoller != null;
327+
bool attachedToPoller = m_attachedPoller != null;
328328

329329
if (attachedToPoller)
330330
{

0 commit comments

Comments
 (0)