patch-2.4.10 linux/net/ipv4/tcp.c
Next file: linux/net/ipv4/tcp_input.c
Previous file: linux/net/ipv4/sysctl_net_ipv4.c
Back to the patch index
Back to the overall index
- Lines: 54
- Date:
Thu Sep 20 14:12:56 2001
- Orig file:
v2.4.9/linux/net/ipv4/tcp.c
- Orig date:
Mon Aug 27 12:41:49 2001
diff -u --recursive --new-file v2.4.9/linux/net/ipv4/tcp.c linux/net/ipv4/tcp.c
@@ -5,7 +5,7 @@
*
* Implementation of the Transmission Control Protocol(TCP).
*
- * Version: $Id: tcp.c,v 1.208 2001/08/13 18:56:12 davem Exp $
+ * Version: $Id: tcp.c,v 1.211 2001/09/20 00:35:35 davem Exp $
*
* Authors: Ross Biro, <bir7@leland.Stanford.Edu>
* Fred N. van Kempen, <waltje@uWalt.NL.Mugnet.ORG>
@@ -852,7 +852,7 @@
page = pages[poffset/PAGE_SIZE];
offset = poffset % PAGE_SIZE;
- size = min(unsigned int, psize, PAGE_SIZE-offset);
+ size = min_t(unsigned int, psize, PAGE_SIZE-offset);
if (tp->send_head==NULL || (copy = mss_now - skb->len) <= 0) {
new_segment:
@@ -1236,7 +1236,7 @@
msg->msg_flags|=MSG_OOB;
if(len>0) {
- if (!(flags & MSG_PEEK) && !(flags & MSG_TRUNC))
+ if (!(flags & MSG_TRUNC))
err = memcpy_toiovec(msg->msg_iov, &c, 1);
len = 1;
} else
@@ -2326,7 +2326,7 @@
if(get_user(len,optlen))
return -EFAULT;
- len = min(unsigned int, len, sizeof(int));
+ len = min_t(unsigned int, len, sizeof(int));
if(len < 0)
return -EINVAL;
@@ -2361,7 +2361,7 @@
val = (val ? : sysctl_tcp_fin_timeout)/HZ;
break;
case TCP_DEFER_ACCEPT:
- val = tp->defer_accept == 0 ? 0 : (TCP_TIMEOUT_INIT<<(tp->defer_accept-1));
+ val = tp->defer_accept == 0 ? 0 : ((TCP_TIMEOUT_INIT/HZ)<<(tp->defer_accept-1));
break;
case TCP_WINDOW_CLAMP:
val = tp->window_clamp;
@@ -2421,7 +2421,7 @@
info.tcpi_advmss = tp->advmss;
info.tcpi_reordering = tp->reordering;
- len = min(unsigned int, len, sizeof(info));
+ len = min_t(unsigned int, len, sizeof(info));
if(put_user(len, optlen))
return -EFAULT;
if(copy_to_user(optval, &info,len))
FUNET's LINUX-ADM group, linux-adm@nic.funet.fi
TCL-scripts by Sam Shen (who was at: slshen@lbl.gov)