Submit #3258 ยป 0001-finger-Remove-T-option.patch
usr.bin/finger/extern.h | ||
---|---|---|
extern time_t now;
|
||
extern int oflag;
|
||
extern int lflag;
|
||
extern int Tflag;
|
||
extern sa_family_t family;
|
||
struct utmpentry;
|
||
usr.bin/finger/finger.1 | ||
---|---|---|
.Nd user information lookup program
|
||
.Sh SYNOPSIS
|
||
.Nm
|
||
.Op Fl 468glmpshoT
|
||
.Op Fl 468glmpsho
|
||
.Op Ar user ...\&
|
||
.Op Ar user@host ...\&
|
||
.Sh DESCRIPTION
|
||
... | ... | |
All name matching performed by
|
||
.Nm
|
||
is case insensitive.
|
||
.It Fl T
|
||
Disable the piggybacking of data on the initial connection request.
|
||
This option is needed to finger hosts with a broken TCP implementation.
|
||
.El
|
||
.Pp
|
||
If no options are specified,
|
usr.bin/finger/finger.c | ||
---|---|---|
DB *db;
|
||
time_t now;
|
||
int entries, gflag, lflag, mflag, pplan, sflag, oflag, Tflag, eightflag;
|
||
int entries, gflag, lflag, mflag, pplan, sflag, oflag, eightflag;
|
||
sa_family_t family = PF_UNSPEC;
|
||
int d_first = -1;
|
||
char tbuf[1024];
|
||
... | ... | |
optind = 1; /* reset getopt */
|
||
while ((ch = getopt(argc, argv, "468glmpshoT")) != -1)
|
||
while ((ch = getopt(argc, argv, "468glmpsho")) != -1)
|
||
switch(ch) {
|
||
case '4':
|
||
family = AF_INET;
|
||
... | ... | |
case 'o':
|
||
oflag = 1; /* office info */
|
||
break;
|
||
case 'T':
|
||
Tflag = 1; /* disable T/TCP */
|
||
break;
|
||
case '?':
|
||
default:
|
||
usage();
|
usr.bin/finger/net.c | ||
---|---|---|
* hosts. Also, the implicit-open API is broken on IPv6, so do
|
||
* the explicit connect there, too.
|
||
*/
|
||
if ((Tflag || ai->ai_addr->sa_family == AF_INET6)
|
||
&& connect(s, ai->ai_addr, ai->ai_addrlen) < 0) {
|
||
if (connect(s, ai->ai_addr, ai->ai_addrlen) < 0) {
|
||
warn("connect");
|
||
close(s);
|
||
return -1;
|