SPIGOT-5472: Spurious warning when using clone command on tile entities
By: md_5 <git@md-5.net>
This commit is contained in:
@@ -62,9 +62,9 @@
|
||||
+
|
||||
+ // CraftBukkit start
|
||||
+ @Override
|
||||
+ public TileEntity getTileEntity(BlockPosition pos) {
|
||||
+ TileEntity result = super.getTileEntity(pos);
|
||||
+ if (Thread.currentThread() != this.serverThread) {
|
||||
+ protected TileEntity getTileEntity(BlockPosition pos, boolean validate) {
|
||||
+ TileEntity result = super.getTileEntity(pos, validate);
|
||||
+ if (!validate || Thread.currentThread() != this.serverThread) {
|
||||
+ // SPIGOT-5378: avoid deadlock, this can be called in loading logic (i.e lighting) but getType() will block on chunk load
|
||||
+ return result;
|
||||
+ }
|
||||
|
||||
Reference in New Issue
Block a user