mirror of
https://github.com/TotalFreedomMC/BukkitTelnet.git
synced 2024-05-24 21:51:24 +00:00
Be a bit more strict on input in order to reduce leaking.
This commit is contained in:
parent
bc3ff0312f
commit
016ed9488d
|
@ -272,10 +272,14 @@ public final class ClientSession extends Thread
|
||||||
}
|
}
|
||||||
catch (IOException ex)
|
catch (IOException ex)
|
||||||
{
|
{
|
||||||
continue;
|
break;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (input == null || input.isEmpty()) // End of stream
|
if (input == null)
|
||||||
|
{
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
if (input.isEmpty())
|
||||||
{
|
{
|
||||||
continue;
|
continue;
|
||||||
}
|
}
|
||||||
|
@ -319,10 +323,14 @@ public final class ClientSession extends Thread
|
||||||
}
|
}
|
||||||
catch (IOException ex)
|
catch (IOException ex)
|
||||||
{
|
{
|
||||||
continue;
|
break;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (input == null || input.isEmpty()) // End of stream
|
if (input == null)
|
||||||
|
{
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
if (input.isEmpty())
|
||||||
{
|
{
|
||||||
continue;
|
continue;
|
||||||
}
|
}
|
||||||
|
@ -371,7 +379,7 @@ public final class ClientSession extends Thread
|
||||||
}
|
}
|
||||||
catch (IOException ex)
|
catch (IOException ex)
|
||||||
{
|
{
|
||||||
continue;
|
break;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (command == null)
|
if (command == null)
|
||||||
|
|
Loading…
Reference in a new issue