This commit is contained in:
Jesse Boyd 2018-04-14 02:23:31 +10:00
parent 39216dee42
commit 5bdc2d6519
No known key found for this signature in database
GPG Key ID: 59F1DE6293AF6E1F

View File

@ -721,13 +721,15 @@ public class LocalSession {
return selector.getRegion(); return selector.getRegion();
} }
public synchronized @Nullable VirtualWorld getVirtualWorld() { public @Nullable VirtualWorld getVirtualWorld() {
return virtual; synchronized (dirty) {
return virtual;
}
} }
public void setVirtualWorld(@Nullable VirtualWorld world) { public void setVirtualWorld(@Nullable VirtualWorld world) {
VirtualWorld tmp; VirtualWorld tmp;
synchronized (this) { synchronized (dirty) {
tmp = this.virtual; tmp = this.virtual;
this.virtual = world; this.virtual = world;
} }