Lines 318-343
Link Here
|
318 |
|
318 |
|
319 |
/* |
319 |
/* |
320 |
* Traverse the list of possible login names and check the login name |
320 |
* Traverse the list of possible login names and check the login name |
321 |
* and real name against the name specified by the user. If the name |
321 |
* and real name against the name specified by the user. |
322 |
* begins with a '/', try to read the file of that name instead of |
|
|
323 |
* gathering the traditional finger information. |
324 |
*/ |
322 |
*/ |
325 |
if (mflag) |
323 |
if (mflag) |
326 |
for (p = argv; *p; ++p) { |
324 |
for (p = argv; *p; ++p) { |
327 |
if (**p != '/' || !show_text("", *p, "")) { |
325 |
if (((pw = getpwnam(*p)) != NULL) && !hide(pw)) |
328 |
if (((pw = getpwnam(*p)) != NULL) && !hide(pw)) |
326 |
enter_person(pw); |
329 |
enter_person(pw); |
327 |
else |
330 |
else |
328 |
warnx("%s: no such user", *p); |
331 |
warnx("%s: no such user", *p); |
|
|
332 |
} |
333 |
} |
329 |
} |
334 |
else { |
330 |
else { |
335 |
while ((pw = getpwent()) != NULL) { |
331 |
while ((pw = getpwent()) != NULL) { |
336 |
for (p = argv, ip = used; *p; ++p, ++ip) |
332 |
for (p = argv, ip = used; *p; ++p, ++ip) |
337 |
if (**p == '/' && *ip != 1 |
333 |
if (match(pw, *p) && !hide(pw)) { |
338 |
&& show_text("", *p, "")) |
|
|
339 |
*ip = 1; |
340 |
else if (match(pw, *p) && !hide(pw)) { |
341 |
enter_person(pw); |
334 |
enter_person(pw); |
342 |
*ip = 1; |
335 |
*ip = 1; |
343 |
} |
336 |
} |