forked from OSchip/llvm-project
[LLDB]Initialize accept_socket with nullptr
Fix high impact issue of illegal access of memory. Initialize accept_socket with nullptr. Differential Revision: https://reviews.llvm.org/D134293
This commit is contained in:
parent
6257832bf9
commit
3ae633766b
|
@ -1233,7 +1233,7 @@ GDBRemoteCommunication::ConnectLocally(GDBRemoteCommunication &client,
|
|||
listen_socket.Listen("localhost:0", backlog).ToError())
|
||||
return error;
|
||||
|
||||
Socket *accept_socket;
|
||||
Socket *accept_socket = nullptr;
|
||||
std::future<Status> accept_status = std::async(
|
||||
std::launch::async, [&] { return listen_socket.Accept(accept_socket); });
|
||||
|
||||
|
|
Loading…
Reference in New Issue