svn commit: r260821 - projects/sendfile/sys/kern

Gleb Smirnoff glebius at FreeBSD.org
Fri Jan 17 11:17:29 UTC 2014


Author: glebius
Date: Fri Jan 17 11:17:28 2014
New Revision: 260821
URL: http://svnweb.freebsd.org/changeset/base/260821

Log:
  Fix logic error from r259821.
  
  Sponsored by:	Netflix
  Sponsored by:	Nginx, Inc.

Modified:
  projects/sendfile/sys/kern/uipc_sockbuf.c

Modified: projects/sendfile/sys/kern/uipc_sockbuf.c
==============================================================================
--- projects/sendfile/sys/kern/uipc_sockbuf.c	Fri Jan 17 11:13:45 2014	(r260820)
+++ projects/sendfile/sys/kern/uipc_sockbuf.c	Fri Jan 17 11:17:28 2014	(r260821)
@@ -938,7 +938,7 @@ sbflush_internal(struct sockbuf *sb)
 		 * Don't call sbdrop(sb, 0) if the leading mbuf is non-empty:
 		 * we would loop forever. Panic instead.
 		 */
-		if (sb->sb_ccc > 0 && (sb->sb_mb == NULL || sb->sb_mb->m_len))
+		if (sb->sb_ccc == 0 && (sb->sb_mb == NULL || sb->sb_mb->m_len))
 			break;
 		m_freem(sbcut_internal(sb, (int)sb->sb_ccc));
 	}


More information about the svn-src-projects mailing list