[prev in list] [next in list] [prev in thread] [next in thread]
List: git-commits-24
Subject: [NET]: Fix SO_{RCV,SND}TIMEO getsockopt handling.
From: Linux Kernel Mailing List <linux-kernel () vger ! kernel ! org>
Date: 2004-06-28 3:41:08
Message-ID: 200407021802.i62I2Yr2032018 () hera ! kernel ! org
[Download RAW message or body]
ChangeSet 1.1462.1.1, 2004/06/27 20:41:08-07:00, davem@nuts.davemloft.net
[NET]: Fix SO_{RCV,SND}TIMEO getsockopt handling.
A microsecond is 1 millionth of a second not
1 thousandth of a second.
Noticed by Markus Mottl <markus@oefai.at>
Signed-off-by: David S. Miller <davem@redhat.com>
sock.c | 4 ++--
1 files changed, 2 insertions(+), 2 deletions(-)
diff -Nru a/net/core/sock.c b/net/core/sock.c
--- a/net/core/sock.c 2004-07-02 11:02:36 -07:00
+++ b/net/core/sock.c 2004-07-02 11:02:36 -07:00
@@ -516,7 +516,7 @@
v.tm.tv_usec = 0;
} else {
v.tm.tv_sec = sk->rcvtimeo/HZ;
- v.tm.tv_usec = ((sk->rcvtimeo%HZ)*1000)/HZ;
+ v.tm.tv_usec = ((sk->rcvtimeo%HZ)*1000000)/HZ;
}
break;
@@ -527,7 +527,7 @@
v.tm.tv_usec = 0;
} else {
v.tm.tv_sec = sk->sndtimeo/HZ;
- v.tm.tv_usec = ((sk->sndtimeo%HZ)*1000)/HZ;
+ v.tm.tv_usec = ((sk->sndtimeo%HZ)*1000000)/HZ;
}
break;
-
To unsubscribe from this list: send the line "unsubscribe bk-commits-24" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
[prev in list] [next in list] [prev in thread] [next in thread]
Configure |
About |
News |
Add a list |
Sponsored by KoreLogic