outdoor users(20)

This commit is contained in:
Louis Farina 2021-02-15 17:17:48 +01:00
parent 03d3c77895
commit 18321eb1ef

View file

@ -37,12 +37,13 @@ class ReceiveThread extends Thread {
}
public void run()
{
ObjectInputStream in;
boolean exit = false;
while(!exit)
{
try
{
ObjectInputStream in = new ObjectInputStream(socket.getInputStream());
in = new ObjectInputStream(socket.getInputStream());
Notification notif = (Notification) in.readObject();
if(!(notif.getAuthor().equals(user)) && !(notif.getAuthor().isOutdoor() && !isOutdoor))
@ -140,6 +141,7 @@ class ReceiveThread extends Thread {
}
catch(Exception e)
{
in.reset();
e.printStackTrace();
/*System.out.println("Socket closed");
dest_sockets.remove(socket);