I'm very pleased to announce the release of our new website and documentation using the new toolchain with Hugo and AsciiDoctor. To get more information about the new toolchain please read the FreeBSD Documentation Project Primer[1], Hugo docs[2] and AsciiDoctor docs[3]. Acknowledgment: Benedict Reuschling <bcr@> Glen Barber <gjb@> Hiroki Sato <hrs@> Li-Wen Hsu <lwhsu@> Sean Chittenden <seanc@> The FreeBSD Foundation [1] https://docs.FreeBSD.org/en/books/fdp-primer/ [2] https://gohugo.io/documentation/ [3] https://docs.asciidoctor.org/home/ Approved by: doceng, core
40 lines
1.1 KiB
Diff
40 lines
1.1 KiB
Diff
Index: finger.c
|
|
===================================================================
|
|
RCS file: /home/ncvs/src/usr.bin/finger/finger.c,v
|
|
retrieving revision 1.15.2.3
|
|
retrieving revision 1.21
|
|
diff -u -r1.15.2.3 -r1.21
|
|
--- finger.c 2000/09/15 21:51:00 1.15.2.3
|
|
+++ finger.c 2000/10/05 15:56:13 1.21
|
|
@@ -293,6 +293,16 @@
|
|
goto net;
|
|
|
|
/*
|
|
+ * Mark any arguments beginning with '/' as invalid so that we
|
|
+ * don't accidently confuse them with expansions from finger.conf
|
|
+ */
|
|
+ for (p = argv, ip = used; *p; ++p, ++ip)
|
|
+ if (**p == '/') {
|
|
+ *ip = 1;
|
|
+ warnx("%s: no such user", *p);
|
|
+ }
|
|
+
|
|
+ /*
|
|
* Traverse the finger alias configuration file of the form
|
|
* alias:(user|alias), ignoring comment lines beginning '#'.
|
|
*/
|
|
@@ -323,11 +333,11 @@
|
|
* gathering the traditional finger information.
|
|
*/
|
|
if (mflag)
|
|
- for (p = argv; *p; ++p) {
|
|
- if (**p != '/' || !show_text("", *p, "")) {
|
|
+ for (p = argv, ip = used; *p; ++p, ++ip) {
|
|
+ if (**p != '/' || *ip == 1 || !show_text("", *p, "")) {
|
|
if (((pw = getpwnam(*p)) != NULL) && !hide(pw))
|
|
enter_person(pw);
|
|
- else
|
|
+ else if (!*ip)
|
|
warnx("%s: no such user", *p);
|
|
}
|
|
}
|