Skip to content

Commit

Permalink
Lucene.Net.Util.RandomizedContext: Updated comments
Browse files Browse the repository at this point in the history
  • Loading branch information
NightOwl888 committed Jan 17, 2025
1 parent ff6b991 commit 4187a33
Showing 1 changed file with 3 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -204,8 +204,8 @@ internal void DisposeResources()
UninterruptableMonitor.Enter(contextLock);
try
{
resources = disposableResources;
disposableResources = null;
resources = disposableResources; // Set the resources to a local variable
disposableResources = null; // Set disposableResources field to null so our local list will go out of scope when we are done
}
finally
{
Expand Down Expand Up @@ -245,7 +245,7 @@ internal void DisposeResources()
ExceptionDispatchInfo.Capture(th).Throw(); // LUCENENET: Rethrow to preserve stack details from the original throw
}
}
} // toDispose goes out of scope here - no need to Clear().
} // resources goes out of scope here - no need to Clear().

/// <summary>
/// Prints a stack trace of the <paramref name="exception"/> to the destination <see cref="TextWriter"/>.
Expand Down

0 comments on commit 4187a33

Please sign in to comment.