Dont accept connections when application down
This commit is contained in:
@@ -930,6 +930,14 @@ final class EMSI extends BaseProtocol implements CRCInterface,ZmodemInterface
|
||||
|
||||
$this->client->rx_purge();
|
||||
$this->client->tx_purge();
|
||||
|
||||
if ($this->down) {
|
||||
Log::info(sprintf('%s:! System down for maintenance',self::LOGKEY));
|
||||
$this->client->buffer_add(self::EMSI_NAK.'Sorry down for maintenance, call back again after a few minutes'.self::CR.self::CR);
|
||||
$this->client->buffer_flush(5);
|
||||
return -1;
|
||||
}
|
||||
|
||||
$this->emsi_banner();
|
||||
|
||||
$t1 = $this->client->timer_set(self::EMSI_HSTIMEOUT);
|
||||
|
Reference in New Issue
Block a user