Skip to content

Commit

Permalink
Merge pull request #9079 from kegilbert/TCPSocket-accept-statelog
Browse files Browse the repository at this point in the history
Add socket stat logging state change update
  • Loading branch information
0xc0170 authored Dec 18, 2018
2 parents eda1952 + ee3945d commit 06748af
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions features/netsocket/TCPSocket.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -288,6 +288,8 @@ TCPSocket *TCPSocket::accept(nsapi_error_t *error)

if (0 == ret) {
connection = new TCPSocket(this, socket, address);
_socket_stats.stats_update_peer(connection, address);
_socket_stats.stats_update_socket_state(connection, SOCK_CONNECTED);
break;
} else if ((_timeout == 0) || (ret != NSAPI_ERROR_WOULD_BLOCK)) {
break;
Expand Down

0 comments on commit 06748af

Please sign in to comment.