mirror of
https://github.com/CitizensDev/Citizens2.git
synced 2024-11-29 14:15:50 +01:00
Experimental change to use less memory for sockets - may break player NPCs
This commit is contained in:
parent
e7244ba118
commit
0c2ba89c55
@ -10,11 +10,13 @@ public class EmptySocket extends Socket {
|
|||||||
|
|
||||||
@Override
|
@Override
|
||||||
public InputStream getInputStream() {
|
public InputStream getInputStream() {
|
||||||
return new ByteArrayInputStream(new byte[10]);
|
return new ByteArrayInputStream(EMPTY);
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public OutputStream getOutputStream() {
|
public OutputStream getOutputStream() {
|
||||||
return new ByteArrayOutputStream();
|
return new ByteArrayOutputStream(1);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
private static final byte[] EMPTY = new byte[0];
|
||||||
}
|
}
|
Loading…
Reference in New Issue
Block a user