summaryrefslogtreecommitdiffhomepage
path: root/conn/bind_windows.go
diff options
context:
space:
mode:
authorJason A. Donenfeld <Jason@zx2c4.com>2023-03-13 17:55:05 +0100
committerJason A. Donenfeld <Jason@zx2c4.com>2023-03-13 17:55:53 +0100
commit0ad14a89f5f9da577dae6a63ad196015e51a0381 (patch)
treeda74ec4dd4dd79b3577236bc30b42ea999e8516b /conn/bind_windows.go
parent7d327ed35aef08e2f54c12645a3002c94c6aec91 (diff)
global: buff -> buf
This always struck me as kind of weird and non-standard. Signed-off-by: Jason A. Donenfeld <Jason@zx2c4.com>
Diffstat (limited to 'conn/bind_windows.go')
-rw-r--r--conn/bind_windows.go12
1 files changed, 6 insertions, 6 deletions
diff --git a/conn/bind_windows.go b/conn/bind_windows.go
index e44cc7b..228167e 100644
--- a/conn/bind_windows.go
+++ b/conn/bind_windows.go
@@ -416,19 +416,19 @@ retry:
return n, &ep, nil
}
-func (bind *WinRingBind) receiveIPv4(buffs [][]byte, sizes []int, eps []Endpoint) (int, error) {
+func (bind *WinRingBind) receiveIPv4(bufs [][]byte, sizes []int, eps []Endpoint) (int, error) {
bind.mu.RLock()
defer bind.mu.RUnlock()
- n, ep, err := bind.v4.Receive(buffs[0], &bind.isOpen)
+ n, ep, err := bind.v4.Receive(bufs[0], &bind.isOpen)
sizes[0] = n
eps[0] = ep
return 1, err
}
-func (bind *WinRingBind) receiveIPv6(buffs [][]byte, sizes []int, eps []Endpoint) (int, error) {
+func (bind *WinRingBind) receiveIPv6(bufs [][]byte, sizes []int, eps []Endpoint) (int, error) {
bind.mu.RLock()
defer bind.mu.RUnlock()
- n, ep, err := bind.v6.Receive(buffs[0], &bind.isOpen)
+ n, ep, err := bind.v6.Receive(bufs[0], &bind.isOpen)
sizes[0] = n
eps[0] = ep
return 1, err
@@ -486,14 +486,14 @@ func (bind *afWinRingBind) Send(buf []byte, nend *WinRingEndpoint, isOpen *atomi
return winrio.SendEx(bind.rq, dataBuffer, 1, nil, addressBuffer, nil, nil, 0, 0)
}
-func (bind *WinRingBind) Send(buffs [][]byte, endpoint Endpoint) error {
+func (bind *WinRingBind) Send(bufs [][]byte, endpoint Endpoint) error {
nend, ok := endpoint.(*WinRingEndpoint)
if !ok {
return ErrWrongEndpointType
}
bind.mu.RLock()
defer bind.mu.RUnlock()
- for _, buf := range buffs {
+ for _, buf := range bufs {
switch nend.family {
case windows.AF_INET:
if bind.v4.blackhole {