outdoor users(20)
This commit is contained in:
parent
03d3c77895
commit
18321eb1ef
1 changed files with 3 additions and 1 deletions
|
@ -37,12 +37,13 @@ class ReceiveThread extends Thread {
|
||||||
}
|
}
|
||||||
public void run()
|
public void run()
|
||||||
{
|
{
|
||||||
|
ObjectInputStream in;
|
||||||
boolean exit = false;
|
boolean exit = false;
|
||||||
while(!exit)
|
while(!exit)
|
||||||
{
|
{
|
||||||
try
|
try
|
||||||
{
|
{
|
||||||
ObjectInputStream in = new ObjectInputStream(socket.getInputStream());
|
in = new ObjectInputStream(socket.getInputStream());
|
||||||
Notification notif = (Notification) in.readObject();
|
Notification notif = (Notification) in.readObject();
|
||||||
|
|
||||||
if(!(notif.getAuthor().equals(user)) && !(notif.getAuthor().isOutdoor() && !isOutdoor))
|
if(!(notif.getAuthor().equals(user)) && !(notif.getAuthor().isOutdoor() && !isOutdoor))
|
||||||
|
@ -140,6 +141,7 @@ class ReceiveThread extends Thread {
|
||||||
}
|
}
|
||||||
catch(Exception e)
|
catch(Exception e)
|
||||||
{
|
{
|
||||||
|
in.reset();
|
||||||
e.printStackTrace();
|
e.printStackTrace();
|
||||||
/*System.out.println("Socket closed");
|
/*System.out.println("Socket closed");
|
||||||
dest_sockets.remove(socket);
|
dest_sockets.remove(socket);
|
||||||
|
|
Loading…
Reference in a new issue