1
0
mirror of https://git.FreeBSD.org/src.git synced 2024-12-15 10:17:20 +00:00

Add the TCP flags to the log message whenever log_in_vain is 1, not

just when set to 2.

PR:		kern/43348
MFC after:	5 days
This commit is contained in:
Crist J. Clark 2003-02-02 22:06:56 +00:00
parent 6607b68526
commit 39eb27a4a9
Notes: svn2git 2020-12-20 02:59:44 +00:00
svn path=/head/; revision=110251
2 changed files with 6 additions and 16 deletions

View File

@ -605,17 +605,12 @@ tcp_input(m, off0)
}
switch (log_in_vain) {
case 1:
if (thflags & TH_SYN)
log(LOG_INFO,
"Connection attempt to TCP %s:%d "
"from %s:%d\n",
dbuf, ntohs(th->th_dport), sbuf,
ntohs(th->th_sport));
break;
if ((thflags & TH_SYN) == 0)
break;
case 2:
log(LOG_INFO,
"Connection attempt to TCP %s:%d "
"from %s:%d flags:0x%x\n",
"from %s:%d flags:0x%02x\n",
dbuf, ntohs(th->th_dport), sbuf,
ntohs(th->th_sport), thflags);
break;

View File

@ -605,17 +605,12 @@ tcp_input(m, off0)
}
switch (log_in_vain) {
case 1:
if (thflags & TH_SYN)
log(LOG_INFO,
"Connection attempt to TCP %s:%d "
"from %s:%d\n",
dbuf, ntohs(th->th_dport), sbuf,
ntohs(th->th_sport));
break;
if ((thflags & TH_SYN) == 0)
break;
case 2:
log(LOG_INFO,
"Connection attempt to TCP %s:%d "
"from %s:%d flags:0x%x\n",
"from %s:%d flags:0x%02x\n",
dbuf, ntohs(th->th_dport), sbuf,
ntohs(th->th_sport), thflags);
break;