Minor optimisation to the tcp_client code

This is minor optimisation to the tcp_client code:

Note that two lines, one is 'send mes error', the other is 'recv msg from server', 
the first 'mes' should be 'msg', for short. The code is more readable.
This commit is contained in:
David Lin
2020-02-14 22:14:48 +08:00
committed by GitHub
parent 59e403891a
commit a36cec2ff1

View File

@@ -38,7 +38,7 @@ void application_entry(void *arg)
printf("send(%d): %s:%d :%s\n", ++cnt, server_ip, server_port, str);
if ((send(socketfd, str, strlen(str), 0)) < 0) {
printf("send mes error: %s errno : %d\n", strerror(errno), errno);
printf("send msg error: %s errno : %d\n", strerror(errno), errno);
goto tcp_client_exit;
}