Skip site navigation (1)Skip section navigation (2)
Date:      Mon, 13 Nov 2017 22:16:47 +0000 (UTC)
From:      Gleb Smirnoff <glebius@FreeBSD.org>
To:        src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org
Subject:   svn commit: r325782 - head/sys/netinet
Message-ID:  <201711132216.vADMGl9p070266@repo.freebsd.org>

next in thread | raw e-mail | index | archive | help
Author: glebius
Date: Mon Nov 13 22:16:47 2017
New Revision: 325782
URL: https://svnweb.freebsd.org/changeset/base/325782

Log:
  Style r320614: don't initialize at declaration, new line after declarations,
  shorten variable name to avoid extra long lines.
  No functional changes.

Modified:
  head/sys/netinet/tcp_output.c

Modified: head/sys/netinet/tcp_output.c
==============================================================================
--- head/sys/netinet/tcp_output.c	Mon Nov 13 21:55:34 2017	(r325781)
+++ head/sys/netinet/tcp_output.c	Mon Nov 13 22:16:47 2017	(r325782)
@@ -523,12 +523,12 @@ after_sack_rexmit:
 	 * XXXGL: should there be used sbused() or sbavail()?
 	 */
 	if (V_tcp_do_autosndbuf && so->so_snd.sb_flags & SB_AUTOSIZE) {
-		int autosndbuf_mod = 0;
-		if (V_tcp_sendbuf_auto_lowat)
-			autosndbuf_mod = so->so_snd.sb_lowat;
+		int lowat;
 
-		if ((tp->snd_wnd / 4 * 5) >= so->so_snd.sb_hiwat - autosndbuf_mod &&
-		    sbused(&so->so_snd) >= (so->so_snd.sb_hiwat / 8 * 7) - autosndbuf_mod &&
+		lowat = V_tcp_sendbuf_auto_lowat ? so->so_snd.sb_lowat : 0;
+		if ((tp->snd_wnd / 4 * 5) >= so->so_snd.sb_hiwat - lowat &&
+		    sbused(&so->so_snd) >=
+		    (so->so_snd.sb_hiwat / 8 * 7) - lowat &&
 		    sbused(&so->so_snd) < V_tcp_autosndbuf_max &&
 		    sendwin >= (sbused(&so->so_snd) -
 		    (tp->snd_nxt - tp->snd_una))) {



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201711132216.vADMGl9p070266>