From 4f183a42093b4983b4e513cd830edaaffba0a7ab Mon Sep 17 00:00:00 2001 From: Dongha Kim Date: Fri, 20 Dec 2024 13:03:30 -0700 Subject: [PATCH] Fix typo, and add debug messages. --- core/federated/network/socket_common.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/core/federated/network/socket_common.c b/core/federated/network/socket_common.c index 45966dfc7..023000049 100644 --- a/core/federated/network/socket_common.c +++ b/core/federated/network/socket_common.c @@ -121,13 +121,14 @@ static int set_socket_bind_option(int socket_descriptor, uint16_t specified_port struct sockaddr_in assigned; socklen_t addr_len = sizeof(assigned); if (getsockname(socket_descriptor, (struct sockaddr*)&assigned, &addr_len) < 0) { - lf_print_error_and_exit("Federate fdailed to retrieve assigned port number."); + lf_print_error_and_exit("Federate failed to retrieve assigned port number."); } used_port = ntohs(assigned.sin_port); } if (result != 0) { lf_print_error_and_exit("Failed to bind the socket. Port %d is not available. ", used_port); } + lf_print_debug("Socket is binded to port %d.", used_port); return used_port; }