Skip to content

Commit

Permalink
fixes func description
Browse files Browse the repository at this point in the history
  • Loading branch information
staheri14 committed Oct 17, 2023
1 parent 75dfb44 commit dc3cae0
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions p2p/conn/connection_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -230,8 +230,8 @@ func TestMConnectionReceiveRate(t *testing.T) {
fmt.Println("peakRecvRate ", peakRecvRate, "maxRecvRate ", maxRecvRate)
}

// maxSendRate returns the maximum send rate in bytes per second based on the MConnection's SendRate and other configs. It is used to calculate the highest expected value for the peak send rate.
// The returned value is slightly higher than the configured SendRate.
// maxRecvRate returns the maximum receive rate in bytes per second based on the MConnection's RecvRate and other configs. It is used to calculate the highest expected value for the peak send rate.
// The returned value is slightly higher than the configured RecvRate.
func (c *MConnection) maxRecvRate() int64 {
sampleRate := 100 * time.Millisecond
recvRate := round(float64(c.config.RecvRate) * sampleRate.Seconds())
Expand Down

0 comments on commit dc3cae0

Please sign in to comment.