Skip to content

Commit

Permalink
fix: remote conn statistic error (#1776)
Browse files Browse the repository at this point in the history
TCP handshake traffic should be counted as upload traffic for the remote connection
  • Loading branch information
sage417 authored Jan 7, 2025
1 parent 1c5f4a3 commit 49d54cc
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion tunnel/tunnel.go
Original file line number Diff line number Diff line change
Expand Up @@ -547,7 +547,7 @@ func handleTCPConn(connCtx C.ConnContext) {
}
logMetadata(metadata, rule, remoteConn)

remoteConn = statistic.NewTCPTracker(remoteConn, statistic.DefaultManager, metadata, rule, 0, int64(peekLen), true)
remoteConn = statistic.NewTCPTracker(remoteConn, statistic.DefaultManager, metadata, rule, int64(peekLen), 0, true)
defer func(remoteConn C.Conn) {
_ = remoteConn.Close()
}(remoteConn)
Expand Down

0 comments on commit 49d54cc

Please sign in to comment.