Skip to content

Commit

Permalink
add null check, exit when context is null
Browse files Browse the repository at this point in the history
  • Loading branch information
ProjectsByJackHe committed Aug 21, 2024
1 parent 7137dcb commit 6fd4ca5
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/perf/lib/Tcp.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -252,7 +252,7 @@ TcpWorker::DoWork(
{
TcpWorker* This = (TcpWorker*)Context;
TcpConnection* Connection;
if (This->Engine->Shutdown) {
if (This == NULL || This->Engine->Shutdown) {
return FALSE;
}
CxPlatDispatchLockAcquire(&This->Lock);
Expand Down

0 comments on commit 6fd4ca5

Please sign in to comment.