Pārlūkot izejas kodu

[telnet server]fix several connection

balbekova 5 gadi atpakaļ
vecāks
revīzija
5576d6ebda
1 mainītis faili ar 6 papildinājumiem un 0 dzēšanām
  1. 6 0
      modules/Telnet_Server/telnet_server.c

+ 6 - 0
modules/Telnet_Server/telnet_server.c

@@ -736,6 +736,12 @@ void vBasicSocketsCommandInterpreterTask( void *pvParameters )
 				else {
 					DBG printf("  Descriptor %d is readable\n", sock);
 
+					for(cur_cnt = 0; cur_cnt < NUMBER_TELNET_CONNECT; cur_cnt ++){
+						if(auth_tlnt_srvr_param[cur_cnt].num_connect == sock){
+							break;
+						}
+					}
+
 					/* Receive data on this connection until the  */
 					/* recv fails with EWOULDBLOCK.  If any other */
 					/* failure occurs, we will close the          */