mirror of
https://github.com/pmmp/PocketMine-MP.git
synced 2025-07-03 00:29:54 +00:00
Added synchronization to GenerationThread::pushMainToThreadPacket()
This commit is contained in:
parent
d991c32435
commit
b5deae7ba0
@ -53,7 +53,9 @@ class GenerationThread extends Thread{
|
|||||||
|
|
||||||
public function pushMainToThreadPacket($str){
|
public function pushMainToThreadPacket($str){
|
||||||
$this->internalQueue[] = $str;
|
$this->internalQueue[] = $str;
|
||||||
|
$this->synchronized(function(){
|
||||||
$this->notify();
|
$this->notify();
|
||||||
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
public function readMainToThreadPacket(){
|
public function readMainToThreadPacket(){
|
||||||
|
Loading…
x
Reference in New Issue
Block a user