reduce ping frequency

pull/255/head v2.0
v2ray 2016-08-20 11:33:22 +02:00
parent 0a34ec0be6
commit d08ffedf48
No known key found for this signature in database
GPG Key ID: 7251FFA14BB18169
1 changed files with 1 additions and 1 deletions

View File

@ -512,7 +512,7 @@ func (this *Connection) flush() {
this.receivingWorker.Flush(current)
this.sendingWorker.Flush(current)
if this.sendingWorker.PingNecessary() || this.receivingWorker.PingNecessary() || current-atomic.LoadUint32(&this.lastPingTime) >= 5000 {
if this.sendingWorker.PingNecessary() || this.receivingWorker.PingNecessary() || current-atomic.LoadUint32(&this.lastPingTime) >= 3000 {
seg := NewCmdOnlySegment()
seg.Conv = this.conv
seg.Command = CommandPing