go.net/ipv4: make variable names clear
R=dave
CC=golang-dev
https://golang.org/cl/6632058
diff --git a/ipv4/helper_unix.go b/ipv4/helper_unix.go
index 4eab775..3a2df84 100644
--- a/ipv4/helper_unix.go
+++ b/ipv4/helper_unix.go
@@ -39,8 +39,8 @@
cv := reflect.ValueOf(c)
switch ce := cv.Elem(); ce.Kind() {
case reflect.Struct:
- nfd := ce.FieldByName("conn").FieldByName("fd")
- switch fe := nfd.Elem(); fe.Kind() {
+ netfd := ce.FieldByName("conn").FieldByName("fd")
+ switch fe := netfd.Elem(); fe.Kind() {
case reflect.Struct:
fd := fe.FieldByName("sysfd")
return int(fd.Int()), nil
diff --git a/ipv4/helper_windows.go b/ipv4/helper_windows.go
index 0733e3e..6de55f8 100644
--- a/ipv4/helper_windows.go
+++ b/ipv4/helper_windows.go
@@ -38,11 +38,11 @@
cv := reflect.ValueOf(c)
switch ce := cv.Elem(); ce.Kind() {
case reflect.Struct:
- fd := ce.FieldByName("conn").FieldByName("fd")
- switch fe := fd.Elem(); fe.Kind() {
+ netfd := ce.FieldByName("conn").FieldByName("fd")
+ switch fe := netfd.Elem(); fe.Kind() {
case reflect.Struct:
- sysfd := fe.FieldByName("sysfd")
- return syscall.Handle(sysfd.Uint()), nil
+ fd := fe.FieldByName("sysfd")
+ return syscall.Handle(fd.Uint()), nil
}
}
return syscall.InvalidHandle, errInvalidConnType