mirror of
https://github.com/tiramisulabs/seyfert.git
synced 2025-07-03 05:26:07 +00:00
fix: zombie connection
This commit is contained in:
parent
2cf182f37e
commit
dd0a3bf65b
@ -210,7 +210,7 @@ export class Shard {
|
|||||||
);
|
);
|
||||||
if (!requested) {
|
if (!requested) {
|
||||||
if (!this.heart.ack) {
|
if (!this.heart.ack) {
|
||||||
this.close(ShardSocketCloseCodes.ZombiedConnection, 'Zombied connection');
|
this.reconnect(ShardSocketCloseCodes.ZombiedConnection);
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
this.heart.ack = false;
|
this.heart.ack = false;
|
||||||
@ -424,6 +424,7 @@ export class Shard {
|
|||||||
case ShardSocketCloseCodes.Reconnect:
|
case ShardSocketCloseCodes.Reconnect:
|
||||||
case ShardSocketCloseCodes.Resharding:
|
case ShardSocketCloseCodes.Resharding:
|
||||||
case ShardSocketCloseCodes.ShutdownAll:
|
case ShardSocketCloseCodes.ShutdownAll:
|
||||||
|
case ShardSocketCloseCodes.ZombiedConnection:
|
||||||
//Force disconnect, ignore
|
//Force disconnect, ignore
|
||||||
break;
|
break;
|
||||||
case 1000:
|
case 1000:
|
||||||
@ -441,7 +442,6 @@ export class Shard {
|
|||||||
break;
|
break;
|
||||||
case 1001:
|
case 1001:
|
||||||
case 1006:
|
case 1006:
|
||||||
case ShardSocketCloseCodes.ZombiedConnection:
|
|
||||||
case GatewayCloseCodes.UnknownError:
|
case GatewayCloseCodes.UnknownError:
|
||||||
case GatewayCloseCodes.DecodeError:
|
case GatewayCloseCodes.DecodeError:
|
||||||
case GatewayCloseCodes.NotAuthenticated:
|
case GatewayCloseCodes.NotAuthenticated:
|
||||||
|
Loading…
x
Reference in New Issue
Block a user