deraadt
9e1200d556
Don't Xr flock, since that is not the locking method used.
ok millert
9 years ago
schwarze
6201910f6e
Remove useless quoting from .Fo and .Fn function names, to prevent
development of a cargo cult in case people look at existing files
for examples. This achieves a consistent .Fo and .Fn quoting style
across the whole tree.
9 years ago
schwarze
0f5a134fe9
in the SYNOPSIS, make void function arguments explicit
9 years ago
schwarze
558404f2f1
reduce more .Nd to one line and kill more .Tn
9 years ago
schwarze
a9afc2531c
reduce .Nd to one line and kill .Tn while here
9 years ago
kettenis
ba19740f18
Remove lies about openpty(4) searching for a free pseudo-tty by iterating
through all existing pseudo-tty devices in /dev.
9 years ago
deraadt
c2feb81bea
remove cast of malloc(), since stdlib.h is included
9 years ago
nicm
0f67cd6d58
Handle malloc(0) returning NULL (which can happen on some other
platforms) by explicitly making imsg->data = NULL when there is no
data. ok deraadt
9 years ago
sobrado
f38d8c1811
typo in manual page.
ok jsing@
9 years ago
nicm
cac6c14d57
Use memset instead of bzero for better portability.
ok gilles claudio doug
9 years ago
deraadt
4db28c17f3
typo in embedded code block; from Ben Cornett
9 years ago
brynet
1493b9464e
bzero cmsgbuf before using it, silences valgrind warnings.
henning@ "sure"
9 years ago
reyk
13bb9544ea
The correct semantic is to check msgbuf_write() for <= 0, not just < 0.
Fix one occurence in imsg_flush() and clarify it the man page.
Discussed with at least blambert@ jsg@ yasuoka@.
OK gilles@
9 years ago
millert
157c2c8d07
Do not assume that asprintf() clears the pointer on failure, which
is non-portable. Also add missing asprintf() return value checks.
OK deraadt@ guenther@ doug@
9 years ago
millert
8c9df4ed4c
Use strtonum() instead of strtoul() when parsing uid/gid so we get
consistent handling of negative ids on 32bit/64bit systems.
The only negative uid/gid allowed is -1 which is special-cased
so it can be preserved when writing the new master.passwd file
instead of being written as an unsigned number. OK deraadt@
9 years ago
millert
daf0c358fa
tzfile.h is an internal header that should never have been installed.
What's worse, the tzfile.h that gets installed is over 20 years old
and doesn't match the real tzfile.h in libc/time. This makes the
tree safe for /usr/include/tzfile.h removal. The TM_YEAR_BASE
define has been moved to time.h temporarily until its usage is
replaced by 1900 in the tree. Actual removal of tzfile.h is pending
a ports build. Based on a diff from deraadt@
10 years ago
millert
b1bfe035b7
Include stdint.h, not limits.h to get SIZE_MAX. OK guenther@
10 years ago
deraadt
75d428b273
Move to the <limits.h> universe.
review by millert, binary checking process with doug, concept with guenther
10 years ago
schwarze
3772d4b01b
remove .Tn; from Jan Stary <hans at stare dot cz>
10 years ago
tedu
94520ae40e
rename blocks to words. bcrypt "blocks" are unrelated to blowfish blocks,
nor are they the same size.
10 years ago
deraadt
1eaa32d2da
declare a local version of MIN(), call it MINIMUM()
(sorry, my other changes were accidentally premature)
10 years ago
deraadt
474792cd61
declare a local version of MIN(), call it MINIMUM()
10 years ago
deraadt
c7195d4619
Do not need sys/param.h
10 years ago
djm
0f0ceb5483
typo in comment: ouput => output
10 years ago
benno
f0ed57e872
return ERANGE instead of ENOMEM, so callers can differentiate real oom
from this case where we have a static buffer and cant realloc.
ok phessler, claudio, reyk
10 years ago
schwarze
eec3844cf9
use the actual function name in .Dt and NAME .Nm, not an alias;
found with mandoc.db(5)
10 years ago
tedu
5ec209fbb9
no first person in man pages.
10 years ago
doug
17c93dbe45
Explain why we deviate slightly from the PBKDF2 standard.
This explanation is based off of Ted's site. Also, fix a comment from
the SHA-1 version.
ok tedu@
10 years ago
schwarze
d5c9ee380f
obvious cases of missing .An;
found with the new mandoc(1) MANDOCERR_AN_MISSING warning;
no text changes
10 years ago
doug
cd356709c6
Delete secret or secret-derived data with explicit_bzero.
concept ok deraadt@
diff looks ok tedu@
10 years ago
guenther
c268bc15d8
Use O_CLOEXEC wherever we open a file and then call fcntl(F_SETFD, FD_CLOEXEC)
on it, simplifying error checking, reducing system calls, and improving
thread-safety for libraries.
ok miod@
10 years ago
tedu
1d810a359a
include stdint.h for standard ints. from Jean-Philippe Ouellet
10 years ago
deraadt
1a1b9e989b
sys/types.h rather than sys/param.h, where applicable. avoid overreach.
10 years ago
deraadt
d1fde0ca73
sort includes much more sensibly
10 years ago
deraadt
55d6095cc3
limits.h rather than sys/param.h
10 years ago
deraadt
a2912d4d42
merge ohash into 1 source file, then we can revisit next roadmap items.
ok espie
10 years ago
jmc
4f0b6ce40e
zap trailing whitespace;
10 years ago
espie
a7f9b5b34c
move the ohash functions into libutil by popular demand.
It's not a standard interface, so it doesn't belong in libc.
I hate duplicating the code in client programs, so do beck@, kettenis@,
schwarze@, millert@, miod@... and they agree with libutil.
10 years ago
tedu
09f67ccdde
fix an error in the stride calculations. the math only works for multiples
of the stride. don't overwrite past the end of the buffer, and also save
that amount for later so the array is completely filled. ok deraadt djm
reported by Dmitry Chestnykh (dchest)
10 years ago
tedu
a0c81f7a45
explicit_bzero where useful
11 years ago
schwarze
fbd81370eb
obvious .Pa fixes; found with mandocdb(8)
11 years ago
jsing
3d91c77a21
Wrap long line.
11 years ago
eric
abf1c90f5d
constify data parameter in imsg_add() and imsg_compose()
ok deraadt@
11 years ago
tedu
daca58aea1
tweak comment
11 years ago
deraadt
4c65102df3
fairly simple unsigned char casts for ctype
ok krw
11 years ago
benno
9acc266dad
document that ibuf_write() and msgbuf_write() can now return EAGAIN
from and with deraadt@
11 years ago
benno
82969df044
original bug diagnosed by sthen: automatic retry in msgbuf_write on
EAGAIN causes spinning.
fix from claudio:
"Let msgbuf_write return -1 with errno EAGAIN. The users then must
check if this was the case and readd the event or poll again. The
current handling in the imsg code is wrong for sure."
ok gilles
11 years ago
millert
39b57a36bb
Fix FILE * leak in error path if fprintf fails. Found by and OK gilles@
11 years ago
guenther
7a9b19976d
Use %lld and cast to (long long) when printing time_t values and atoll()
when parsing them.
Add a couple [ug]id_t --> u_int casts for consistency with rest of code.
Based on a diff from Nathanael Rensen (nathanael (at) polymorpheus.com)
11 years ago
jmc
0c51a5a453
some Bx/Ox conversion;
From: Jan Stary
11 years ago