messageTCP

This commit is contained in:
LMAGallois 2020-12-09 09:54:09 +01:00
parent 844ddcdc4d
commit 85d0725ff3
2 changed files with 5 additions and 3 deletions

View file

@ -3,7 +3,7 @@ public class Database {
private User myUser;
public void Database() {
Connection con=null;
}
}

View file

@ -38,9 +38,11 @@ public class UserListeningThreadTCP extends Thread{
}
public void accept(ServerSocket servSocket) throws IOException {
UserConnexionthreadTCP threadtcp= new UserConnexionthreadTCP("Chat_with_"+myUser.getPseudo(),myUser,servSocket.accept());
Socket socket_tcp= servSocket.accept();
UserConnexionthreadTCP threadtcp= new UserConnexionthreadTCP("Chat_with_"+myUser.getPseudo(),myUser,socket_tcp);
threadtcp.start();
threadtcp.interrupt();
}