Skip to content

Commit 3064728

Browse files
authored
Update Http3Connection lock objects to be readonly (#22263)
1 parent 2787157 commit 3064728

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/Servers/Kestrel/Core/src/Internal/Http3/Http3Connection.cs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -31,13 +31,13 @@ internal class Http3Connection : IRequestProcessor, ITimeoutHandler
3131

3232
private long _highestOpenedStreamId; // TODO lock to access
3333
private volatile bool _haveSentGoAway;
34-
private object _sync = new object();
34+
private readonly object _sync = new object();
3535
private MultiplexedConnectionContext _multiplexedContext;
3636
private readonly Http3ConnectionContext _context;
3737
private readonly ISystemClock _systemClock;
3838
private readonly TimeoutControl _timeoutControl;
3939
private bool _aborted;
40-
private object _protocolSelectionLock = new object();
40+
private readonly object _protocolSelectionLock = new object();
4141

4242
public Http3Connection(Http3ConnectionContext context)
4343
{

0 commit comments

Comments
 (0)