Commit Graph

6648 Commits

Author SHA1 Message Date
tjr
a1bce5d548 Use errc(). 2004-03-22 09:33:10 +00:00
cperciva
cbd95cfcfc 1. Use socklen_t instead of int
2. Compare socket(2) return code to -1, not <= 0.

Obtained from:	OpenBSD rev. 1.9
2004-03-21 08:14:39 +00:00
des
854f282025 Support C-style comments in profile. 2004-03-21 04:47:54 +00:00
ru
5d4e87542e More cleanups:
- 0 should have been -1 in previous commit (just to stay consistent),
- Spell null pointers as NULL, not 0,
- Fixed the comment about pr_usesysctl to not confuse it with boolean.

Pointed by:	bde
2004-03-18 07:21:31 +00:00
ru
4bafff45c6 NULL -> 0. 2004-03-17 20:19:45 +00:00
ru
1837ea9bf5 Improved incorrect usage diagnostics. 2004-03-17 11:06:40 +00:00
ru
50bea8bbbe Trust bsd.prog.mk to set SRCS correctly. 2004-03-17 10:52:12 +00:00
ru
89525cfb11 GC unnecessary include file. 2004-03-17 10:51:18 +00:00
thierry
ffa157ec1e Approved by: mat (mentor). 2004-03-16 19:39:11 +00:00
ru
be0b9fa1ef Catch up with the removal of the wt(4) driver. 2004-03-14 12:09:43 +00:00
jmallett
f12ed405d1 Add multiple inclusion guards. Mostly this is for extern.h, which was
included twice by lprint.c, which included both finger.h and extern.h.
finger.h, in turn, includes extern.h.  The redundant include of extern.h
was removed from lprint.c, as part of this change, but the include guards
were added anyway out of spite.
2004-03-14 06:43:34 +00:00
bde
b515b12ae3 Fixed misspellings of 0 as NULL. Fixed some nearby style bugs. 2004-03-14 05:55:16 +00:00
bde
8c9350e00d Fixed a misspelling of 0 as NULL. 2004-03-14 05:51:20 +00:00
imp
f6d28bfe48 With the passing of the asc driver, the sasc prograqm is no longer
necessary.
2004-03-14 04:59:17 +00:00
des
08e8eb2b40 Do not print a warning about net.inet.pim.stats if errno is
ENOENT, because that means we do not have PIM in the kernel.

Submitted by:	hmp
MFC after:	1 week
2004-03-12 11:22:50 +00:00
bde
0f0e6e75d4 Fixed a misspelling of 0 as NULL.
Fixed a nearby bug.  The "play it safe" code in dosysctl() was unsafe
because it overran the buffer by 1 if sysctl() filled all of the buffer.

Fixed a nearby style bug in output.  Not just 1, but 2 extra newlines
were printed at the end by "vmstat -m" and "vmstat -z".  Don't print
any newlines explicitly.  This depends on 2 of the many formatting
bugs in the corresponding sysctls.  First, the sysctls return an extra
newline at the end of the strings.  This also messes up output from
sysctl(8).  Second, the sysctls return an extra newline at the beginning
of the strings.  This is good for separating the 2 tables output by
"vmstat -mz" and for starting the header on a new line in plain sysctl
output, but gives a bogus extra newline at the beginning for "vm -[m | z]"
and "sysctl -n [kern.malloc | vm.zone]".

Fixed some nearby style bugs in the source code:
- the same line that misspelled 0 as NULL also spelled NULL as 0.
- the size was doubled twice in the realloc loop.
- the "play it safe" comment was misleading.  Terminating the buffer
  is bogus because dosysctl() is only meant to work with sysctls that
  return strings and the terminator is part of a string.  However, the
  kern.malloc sysctl has more than style bugs.  It also doesn't return
  a string.  Termination is needed to work around this bug.
2004-03-11 11:30:57 +00:00
josef
11f4a07713 Replace <iostream.h> with <iostream> to remove annoying warning
of using deprecated header.

Approved by:    dwhite, simon(mentor)
Reviewed by:    mlaier
Submitted by:   Stefan Farfeleder <stefan@fafoe.narf.at>
PR:             bin/63781
2004-03-11 10:43:35 +00:00
bde
2cbaf5127c Fixed a misspelling of '\0' as NULL. 2004-03-11 10:22:25 +00:00
bde
073d9d9542 Fixed misspellings of 0 as NULL. 2004-03-11 10:19:45 +00:00
bde
3c804431a0 Fixed misspellings of '\0' as NULL. 2004-03-11 10:12:05 +00:00
bde
c4ea3a2d24 Fixed a misspelling of 0 as NULL. 2004-03-11 10:09:01 +00:00
ru
476dad3fbe Reworked the fix to print the useful line number on error in
the .for loop:

- Replaced four global variables in parse.c with one.
- Made Parse_FromString() accept the "lineno" as an argument.
- Fixed line numbering when there are escaped newlines in the
  body of the .for loop.

Adopted from:	NetBSD
2004-03-10 21:51:06 +00:00
peadar
ee010adacb Another April Fool signs up. 2004-03-10 00:06:01 +00:00
ru
f490416179 Make it possible to ``.undef ${VAR}'' (expanding VAR to get
the variable name to undef).

Submitted by:	Cyrille Lefevre
2004-03-09 17:36:55 +00:00
dwmalone
24ee2482d3 Fix the easy warnings:
1) Avoid shadowing index.
2) Constness.
3) Missing prototype for ifcmd.
4) Missing include of string.h.
5) Avoid shadowing error function.
6) ANSI definition for main.
2004-03-09 11:57:28 +00:00
dwmalone
036b26782d Misc fixes brought to light by WARNS=6:
1) Constness, unusedness and size_tness.
2) Don't clobber the value returned by hid_report_size in the daemon case.
3) Don't misspell "sizeof buf" as 100.
4) Don't run off the end of a buffer if the pid is about a google.
5) Avoid shadowing the usage function.
2004-03-09 11:35:43 +00:00
ru
a328a35e4a Fixed line numbering inside the .for loops.
Submitted by:	Cyrille Lefevre
2004-03-09 08:09:33 +00:00
mikeh
39dab43424 These aren't all binary options. 2004-03-09 01:20:24 +00:00
cperciva
41b17057ef Make it possible for the %[eEfgG] formats to not result in an error
being reported by /usr/bin/printf.

This bug has been around for 22 months... either nobody uses printf
with floating-point values, or people are forgetting to check their
return codes.

Approved by:	rwatson (mentor)
2004-03-07 22:22:13 +00:00
des
b8d5a64b35 Fix markup.
Submitted by:	ru
2004-03-06 23:36:41 +00:00
des
7f2329af2a Hook logins(1) up to the build. 2004-03-06 21:57:47 +00:00
des
247bd59f13 Add a logins(1) utility similar to that found in SVr4 derivatives. This
particular implementation is based on the Solaris logins(1) man page.
2004-03-06 21:57:29 +00:00
mikeh
97dc367f93 Assign checkmode boolean earlier to handle the goto jump.
Might fix PR bin/63769.
2004-03-06 13:27:59 +00:00
wes
c1543e1757 Use getopt instead of hand-rolled argument parsing. Usage remains
the same, no man page changes required.

PR:		bin/48313
Submitted by:	Stefan Farfeleder <stefan@fafoe.dyndns.org>
Reviewed by:	joe@
2004-03-05 01:52:09 +00:00
josef
afe5d995f8 Update URL of GCC status page to GCC 3.3
Approved by:    simon(mentor)
Submitted by:   Stefan Farfeleder <stefan@fafoe.narf.at>
PR:             docs/63370
2004-03-04 20:29:27 +00:00
blackend
69e1aa030e Typo fix.
PR:		docs/63677
Submitted by:	Volker Stolz <stolz@i2.informatik.rwth-aachen.de>
MFC after:	1 week
2004-03-03 09:15:07 +00:00
jake
4561edec30 Elf_Phdr.p_type 7 is "PT_TLS". 2004-03-02 14:06:27 +00:00
mikeh
9d29f488ff Add the -e (mail presence test), -H (header summary mode), and -F
(message save as first recipient) options for standards
conformance.

Submitted by:	Wartan Hachaturow <wart@tepkom.ru> (with some changes)
PR:		standards/61934
2004-02-29 20:44:44 +00:00
schweikh
4550c31364 Fix grammar bogon. 2004-02-29 12:52:21 +00:00
bde
6becbe0dc5 Fixed style bugs in previous commit (.ifndef instead of .if defined(),
and tab lossage).

Garbage-collected NEED_LIBNAMES.
2004-02-29 06:39:11 +00:00
trhodes
1584bc6304 Update the find manual page:
1: Document -follow under COMPATIBILITY.
2: Update an example to be a little more 'safe'.
3: Use '/' in place of '.' for an example; similar to other manual pages.

PR:		40196 (1), 39532 (2, 3)
Submitted by:	Marc Silver <marcs@draenor.org> (2 and 3)
Discussed with:	des (1)
2004-02-27 20:04:38 +00:00
des
c0a273eb0a I am a moron. 2004-02-27 19:00:41 +00:00
des
b7f41a2806 Re-add the setuid bit, conditional on NO_SETUID_LOGIN being undefined. 2004-02-27 17:50:59 +00:00
des
cc042ab91e Remove EXAMPLES section which duplicates text in fetch(3). 2004-02-27 10:27:01 +00:00
des
8638aa49b9 Cut through the bikeshed and remove login(1)'s setuid bit. It has no
business trying to impersonate su(1), and it does not need to be setuid
to function properly when invoked by getty(8) or telnetd(8).
2004-02-27 08:39:16 +00:00
des
33fda27b84 Use the -H option instead of the deprecated -follow predicate. 2004-02-25 21:45:41 +00:00
bde
e6ece13794 Demangled vendor ids. Fixed misplaced FreeBSD id. 2004-02-25 13:26:53 +00:00
bde
098541a941 Backed out rev.1.6. A bogus include was added to work around breakage of
<netinet/tcp_var.h>'s prerequisites.  Prerequistes should not grow for
userland headers, and <netinet/tcp_var.h> is unfortunately still needed
in userland.
2004-02-25 13:11:48 +00:00
cperciva
b7c97176f0 Send birthday presents to Wadham College, Oxford. :)
Approved by:	rwatson (mentor)
2004-02-24 01:44:47 +00:00
markus
cf29d0ac9e Add my birthday.
Approved by:	arved (mentor)
2004-02-23 20:39:23 +00:00