Skip to content

Commit 8ffc92f

Browse files
committed
fixup
1 parent 7468d90 commit 8ffc92f

File tree

1 file changed

+9
-5
lines changed

1 file changed

+9
-5
lines changed

RabbitMQ.AMQP.Client/Impl/AmqpConnection.cs

Lines changed: 9 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -264,7 +264,7 @@ void OnOpened(Amqp.IConnection connection, Open open1)
264264
catch (Exception ex)
265265
{
266266
throw new ConnectionException(
267-
$"{ToString()} connection failed.", ex);
267+
$"{ToString()} connection failed.", ex);
268268
}
269269

270270
if (_nativeConnection.IsClosed)
@@ -412,11 +412,12 @@ await _recordingTopologyListener.Accept(visitor)
412412
}
413413

414414
OnNewStatus(State.Open, null);
415-
// after the connection is recovered we have to reconnect all the publishers and consumers
416415

416+
// after the connection is recovered we have to reconnect all the publishers and consumers
417417
try
418418
{
419-
await ReconnectEntitiesAsync().ConfigureAwait(false);
419+
await ReconnectEntitiesAsync()
420+
.ConfigureAwait(false);
420421
}
421422
catch (Exception e)
422423
{
@@ -434,11 +435,14 @@ await _recordingTopologyListener.Accept(visitor)
434435
}
435436
finally
436437
{
437-
// TODO it is odd to have to add this check
438-
if (false == _disposed)
438+
// TODO it is odd to have to add this code, figure out why
439+
try
439440
{
440441
_semaphoreClose.Release();
441442
}
443+
catch (ObjectDisposedException)
444+
{
445+
}
442446
}
443447
};
444448
}

0 commit comments

Comments
 (0)