13
0
geforkt von Mirrors/Paper

Fix Heisenplayers

Dieser Commit ist enthalten in:
Wesley Wolfe 2012-06-17 01:25:01 -05:00
Ursprung ae98a6f051
Commit 6bbae461d5

Datei anzeigen

@ -21,7 +21,7 @@ public class NetworkManager {
private DataInputStream input; private DataInputStream input;
private DataOutputStream output; private DataOutputStream output;
private boolean l = true; private boolean l = true;
private List m = Collections.synchronizedList(new ArrayList()); private java.util.Queue m = new java.util.concurrent.ConcurrentLinkedQueue(); // CraftBukkit - Concurrent linked queue
private List highPriorityQueue = Collections.synchronizedList(new ArrayList()); private List highPriorityQueue = Collections.synchronizedList(new ArrayList());
private List lowPriorityQueue = Collections.synchronizedList(new ArrayList()); private List lowPriorityQueue = Collections.synchronizedList(new ArrayList());
private NetHandler packetListener; private NetHandler packetListener;
@ -224,7 +224,7 @@ public class NetworkManager {
int i = 1000; int i = 1000;
while (!this.m.isEmpty() && i-- >= 0) { while (!this.m.isEmpty() && i-- >= 0) {
Packet packet = (Packet) this.m.remove(0); Packet packet = (Packet) this.m.poll(); // CraftBukkit - remove -> poll
if (!this.q) packet.handle(this.packetListener); // CraftBukkit if (!this.q) packet.handle(this.packetListener); // CraftBukkit
} }