Skip to content

Commit 7c57728

Browse files
committed
fixup
1 parent 0587bdf commit 7c57728

File tree

1 file changed

+9
-3
lines changed

1 file changed

+9
-3
lines changed

projects/Test/AsyncIntegration/AsyncIntegrationFixture.cs

Lines changed: 9 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -96,12 +96,18 @@ public virtual async Task DisposeAsync()
9696
{
9797
try
9898
{
99-
await _channel.CloseAsync();
100-
_conn.Close();
99+
if (_channel != null)
100+
{
101+
await _channel.CloseAsync();
102+
}
103+
await _conn.CloseAsync();
101104
}
102105
finally
103106
{
104-
_channel.Dispose();
107+
if (_channel != null)
108+
{
109+
_channel.Dispose();
110+
}
105111
_conn.Dispose();
106112
_channel = null;
107113
_conn = null;

0 commit comments

Comments
 (0)