mirror of
https://github.com/PaperMC/Paper.git
synced 2025-01-01 17:01:56 +01:00
Alter last to force conflicts but keep contents
This commit is contained in:
parent
a36e2a4378
commit
1881616f15
1 changed files with 63 additions and 36 deletions
|
@ -24,19 +24,25 @@ index 0000000000000000000000000000000000000000..00000000000000000000000000000000
|
|||
this.m();
|
||||
this.a(packet, (GenericFutureListener[]) null);
|
||||
- } else {
|
||||
+ }
|
||||
+ // Paper start
|
||||
+ /* else {
|
||||
this.j.writeLock().lock();
|
||||
|
||||
try {
|
||||
@@ -0,0 +0,0 @@ public class NetworkManager extends SimpleChannelInboundHandler<Packet<?>> {
|
||||
} finally {
|
||||
this.j.writeLock().unlock();
|
||||
}
|
||||
- }
|
||||
- this.j.writeLock().lock();
|
||||
-
|
||||
+ }*/
|
||||
- try {
|
||||
- this.i.add(new NetworkManager.QueuedPacket(packet, (GenericFutureListener[]) null));
|
||||
- } finally {
|
||||
- this.j.writeLock().unlock();
|
||||
- }
|
||||
}
|
||||
-
|
||||
+ // Paper start - Remove but force a conflict
|
||||
+// else {
|
||||
+// this.j.writeLock().lock();
|
||||
+//
|
||||
+// try {
|
||||
+// this.i.add(new NetworkManager.QueuedPacket(packet, (GenericFutureListener[]) null));
|
||||
+// } finally {
|
||||
+// this.j.writeLock().unlock();
|
||||
+// }
|
||||
+// }
|
||||
+ // Paper end
|
||||
}
|
||||
|
||||
|
@ -45,19 +51,25 @@ index 0000000000000000000000000000000000000000..00000000000000000000000000000000
|
|||
this.m();
|
||||
this.a(packet, (GenericFutureListener[]) ArrayUtils.add(agenericfuturelistener, 0, genericfuturelistener));
|
||||
- } else {
|
||||
+ }
|
||||
+ // Paper start
|
||||
+ /*
|
||||
+ else {
|
||||
this.j.writeLock().lock();
|
||||
|
||||
try {
|
||||
@@ -0,0 +0,0 @@ public class NetworkManager extends SimpleChannelInboundHandler<Packet<?>> {
|
||||
this.j.writeLock().unlock();
|
||||
}
|
||||
- this.j.writeLock().lock();
|
||||
-
|
||||
- try {
|
||||
- this.i.add(new NetworkManager.QueuedPacket(packet, (GenericFutureListener[]) ArrayUtils.add(agenericfuturelistener, 0, genericfuturelistener)));
|
||||
- } finally {
|
||||
- this.j.writeLock().unlock();
|
||||
- }
|
||||
}
|
||||
-
|
||||
+ */
|
||||
+ // Paper start - Remove but force a conflict
|
||||
+// else {
|
||||
+// this.j.writeLock().lock();
|
||||
+//
|
||||
+// try {
|
||||
+// this.i.add(new NetworkManager.QueuedPacket(packet, (GenericFutureListener[]) ArrayUtils.add(agenericfuturelistener, 0, genericfuturelistener)));
|
||||
+// } finally {
|
||||
+// this.j.writeLock().unlock();
|
||||
+// }
|
||||
+// }
|
||||
+ // Paper end
|
||||
}
|
||||
|
||||
|
@ -67,17 +79,34 @@ index 0000000000000000000000000000000000000000..00000000000000000000000000000000
|
|||
|
||||
private void m() {
|
||||
- if (this.channel != null && this.channel.isOpen()) {
|
||||
+ // Paper start
|
||||
+ /* if (this.channel != null && this.channel.isOpen()) {
|
||||
this.j.readLock().lock();
|
||||
|
||||
try {
|
||||
@@ -0,0 +0,0 @@ public class NetworkManager extends SimpleChannelInboundHandler<Packet<?>> {
|
||||
this.j.readLock().unlock();
|
||||
}
|
||||
|
||||
- this.j.readLock().lock();
|
||||
-
|
||||
- try {
|
||||
- while (!this.i.isEmpty()) {
|
||||
- NetworkManager.QueuedPacket networkmanager_queuedpacket = (NetworkManager.QueuedPacket) this.i.poll();
|
||||
-
|
||||
- this.a(networkmanager_queuedpacket.a, networkmanager_queuedpacket.b);
|
||||
- }
|
||||
+ }*/
|
||||
- } finally {
|
||||
- this.j.readLock().unlock();
|
||||
- }
|
||||
-
|
||||
- }
|
||||
+ // Paper start - Remove but force a conflict
|
||||
+// if (this.channel != null && this.channel.isOpen()) {
|
||||
+// this.j.readLock().lock();
|
||||
+//
|
||||
+// try {
|
||||
+// while (!this.i.isEmpty()) {
|
||||
+// NetworkManager.QueuedPacket networkmanager_queuedpacket = (NetworkManager.QueuedPacket) this.i.poll();
|
||||
+//
|
||||
+// this.a(networkmanager_queuedpacket.a, networkmanager_queuedpacket.b);
|
||||
+// }
|
||||
+// } finally {
|
||||
+// this.j.readLock().unlock();
|
||||
+// }
|
||||
+//
|
||||
+// }
|
||||
+ // Paper end
|
||||
}
|
||||
|
||||
|
@ -92,5 +121,3 @@ index 0000000000000000000000000000000000000000..00000000000000000000000000000000
|
|||
|
||||
}
|
||||
--
|
||||
2.9.3 (Apple Git-75)
|
||||
|
||||
|
|
Loading…
Reference in a new issue