Re: Recent full disclosure post - Local DOS
--SUOF0GtieIMvvwua
Content-Type: text/plain; charset=us-ascii
Content-Disposition: inline
Content-Transfer-Encoding: quoted-printable
On Fri, Jan 28, 2011 at 02:27:18PM -0500, John Baldwin wrote:
[..]
> =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D
> --- tcp_usrreq.c (revision 218018)
> +++ tcp_usrreq.c (working copy)
> @@ -1330,7 +1330,8 @@ tcp_ctloutput(struct socket *so, struct sockopt *s
> tp->t_flags |=3D TF_NOPUSH;
> else {
> tp->t_flags &=3D ~TF_NOPUSH;
> - error =3D tcp_output(tp);
> + if (TCPS_HAVEESTABLISHED(tp->t_state))
> + error =3D tcp_output(tp);
> }
> INP_WUNLOCK(inp);
> break;
I was thinking of correcting it the same way.. I might even do something
like:
else {
if (tp->t_flags & TF_NOPUSH) {
tp->t_flags &=3D ~TF_NOPUSH;
if (TCPS_HAVEESTABLISHED(tp->t_state))
error =3D tcp_output(tp);
}
}
By default, this mask is not set.. so un-setting it and calling tcp_output(=
)=20
if it was not already set seems wasteful
--=20
() ascii ribbon campaign - against html e-mail=20
/\ www.asciiribbon.org - against proprietary attachments
--SUOF0GtieIMvvwua
Content-Type: application/pgp-signature
Content-Disposition: inline
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.9 (FreeBSD)
iEYEARECAAYFAk1DX6gACgkQzHFpVAM/ozy8bQCeNtF3+gblw3B8qOCKMV64LhEO
sTcAn1WHorzA33/saFpWaoaEbmUoUenG
=bNbf
-----END PGP SIGNATURE-----
--SUOF0GtieIMvvwua--
討論串 (同標題文章)
完整討論串 (本文為第 8 之 12 篇):