Skip to content

Commit 93cd0e3

Browse files
committed
Fixed potentially invalid access in json message
1 parent f909eeb commit 93cd0e3

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/debugger/xdap_tcp_client_impl.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -57,7 +57,7 @@ namespace xeus
5757
send_dap_request(std::move(req));
5858
auto rep = wait_for_message([](const nl::json& msg)
5959
{
60-
return msg["command"] == "threads";
60+
return msg.contains("command") && msg["command"] == "threads";
6161
});
6262
nl::json new_message = message;
6363
new_message["body"]["threadList"] = nl::json::array();

0 commit comments

Comments
 (0)