Age | Commit message (Collapse) | Author |
|
|
|
|
|
local traffic is not optional.
ok mikeb@, stsp@, jca@
|
|
|
|
the /var/crash/programname/ directory, as root. For instance,
# mkdir /var/crash/bgpd/
# chmod 700 /var/crash/bgpd/ # If you skip this step, you are a moron
# sysctl kern.nosuidcoredump=3
# bgpd
# pkill -ABRT bgpd
# ls /var/crash/bgpd/
14764.core 23207.core 6423.core
Of course, in real life the idea is that you don't kill the daemon but it
crashes and you collect parallel cores. Careful you don't fill your /var.
Further tuneables are being considered.
Sorry to be picking on bgpd for this example. I've watched the "too
difficult to debug privsep code" angst for far too long.
ok guenther
|
|
|
|
OK from jmc@, and thanks to sthen@ for pointing out my mistake in the first
version of the diff.
|
|
|
|
|
|
Prodded by deraadt@
|
|
value to use for the strerror() message as an argument. Originally from
FreeBSD 3.0
Patch from Steffen Nurpmeso (sdaoden (at) gmail.com) with minor tweaks.
|
|
rework the wording for both IPv4 and IPv6.
OK from sthen@, henning@ and claudio@
|
|
-maxdynroutes
-maxifprefixes
-maxifdefrouters
-neighborgcthresh
OK from sthen@, claudio@ and henning@
|
|
include <sys/vmmeter.h> where it is needed instead of relying on
it being included by <uvm/uvm_extern.h>.
miod@ likes it, ok guenther@
|
|
|
|
(namespace pollution!) or talking about its opinion on code.
ok krw@
|
|
don;t cross reference (Xr) its also no longer available man page: use Fn
instead;
|
|
Fix the description of the RETURN VALUES of get*_r().
Minor polishing while here.
Feedback and ok jmc@, ok millert@ jca@.
|
|
errno; they might do so on open() and close() failures, but by POSIX,
they are not supposed to fail. Note that ignoring failures inside
setgrent() does not matter, the following getgrent() is bound to
fail the same way again, anyway. If you insist on detecting open()
failure, use setgroupent(), even though that is less portable.
While here, remove two pointless (void) casts.
ok millert@ jca@
|
|
error occurs, but of course they do return the error. This matches
what getgr{nam,gid}_r() have already been doing. Original idea
by kettenis@, and deraadt@ called that idea "the only sane approach".
ok kettenis@ millert@
|
|
Save a cookie pointing to the very first entry in the DIR.dd_buf
cache buffer and use that to speed up seekdir(3) when rewinding
to that first entry.
No libc bump because DIR is an opaque struct.
When the optimization applies, which in particular it always does
for rewinddir(3) after reading less than about 500 entries,
seekdir(3) execution time drops from 100 to 0.05 milliseconds
on my i386 notebook. Other cases are not slowed down.
Based on an idea from and ok by guenther@.
|
|
Prevent close(2) and syslog(3) from stomping on errno; from guenther@.
Set ERANGE if the buf is too small, required by POSIX; from jca@.
ok millert@
|
|
Use explicit_bzero in the example code.
|
|
and getgrgid_r() to agree with POSIX. Not touching errno handling
yet, which will also need fixing.
Problem originally reported by william at 25thandClement dot com on bugs@.
OK sthen@, and kettenis@ agrees it's "a step in the right direction".
|
|
and do not point programmers at the obsolete usleep(3);
based on a diff from Jan Klemkow <j dot klemkow at wemelug dot de>,
but removing more as suggested by jmc@ and deraadt@
|
|
tweaking and ok millert@ jmc@
|
|
problem reproduced and fix verified by schwarze who wrote the code
ok krw@ deraadt@ schwarze@
|
|
|
|
While here, improve the wording at one place.
OK jmc@.
|
|
|
|
1. integer division can give an off-by-one (like 2/3 = 0 for calloc)
2. ending the shells array with NULL takes space, too
ok millert@
|
|
format handling wrapper. __fdnlist is used by libkvm. Avoid cranking
libc because the time is inconvenient, and __elf_fdnlist is not used
anywhere.
ok millert jsing
|
|
marking up words that are not trademarks (ASCII, I/O, NFS, TCP, TELNET).
While here, remove .Tn markup from the same words in the body
of these pages, too.
|
|
Found while testing mandocdb(8).
|
|
ok gilles@, millert@
|
|
ok jca krw ingo
|
|
|
|
d_secperunith and p_offseth are set to 0 since they can't be read
from disktab and lower 32 bits (d_secperunit and p_offset) are read
directly from the input.
|
|
setpassent(stayopen).
Bug found and fixed by Erik Lax <erik-AT-halon-DOT-se>
ok millert@ guenther@
|
|
|
|
|
|
prototypes
|
|
|
|
ok guenther
|
|
Consequently, the "skipdeleted" argument is always == 1.
Remove it, effectively reverting readdir.c rev. 1.14.
ok millert@ guenther@
|
|
getdents(2). No functional change, but considerable speedup in many
cases, see http://marc.info/?l=openbsd-tech&m=138369623117934 for some
approximate numbers.
ok guenther@, "good diagnosis" deraadt@
|
|
1. avoid code duplication in rewinddir() by calling seekdir() directly
2. move __seekdir() into seekdir() and _telldir_unlocked() into telldir()
Both functions were called from nowhere else.
3. remove some unused #include directives and one unused function prototype
ok otto@ millert@
|
|
pending entries: At the time of the lseek(2), also invalidate the
buffer in order to force getdents(2) during the next readdir(3).
Because this throws away buffered data that could still be used
in some cases, this is not particularly efficient, but at least
it works; i will suggest optimizations soon.
Bug found when investigating perl-5.18.1/t/op/threads-dirh.t
that was reported broken by Andrew Fresh <andrew at afresh1 dot com>.
ok guenther@ deraadt@
|
|
ports tree grep run by sthen
|
|
|