Пример #1
0
 /*
  * Manages the message received from the client
  */
 private void ReceiveMsg(string data, byte[] bytes, int numByte, Socket clientSocket)
 {
     data += Encoding.ASCII.GetString(bytes, 0, numByte);
     if (data.Equals(""))
     {
         Shutdown(clientSocket);
     }
     else
     {
         _serverUser.Receive_msg(data);
     }
 }
Пример #2
0
 private static void ReceiveMsg(string data, byte[] bytes, int numByte, Socket clientSocket)
 {
     /*
      * Gestiona el mensaje recibido desde el cliente
      */
     data += Encoding.ASCII.GetString(bytes, 0, numByte);
     if (debugging)
     {
         print("Text received -> " + data);
     }
     if (data.Equals(""))
     {
         Shutdown(clientSocket);
     }
     else
     {
         _serverUser.Receive_msg(data);
     }
 }