Commit Graph

6 Commits

Author SHA1 Message Date
Jilles Tjoelker
afa04e4170 sem: Don't free nameinfo that is still in list when open() fails.
This bug could be reproduced easily by calling sem_open() with O_CREAT |
O_EXCL on a semaphore that is already open in the process. The struct
sem_nameinfo would be freed while still in sem_list and later calls to
sem_open() or sem_close() could access freed memory.

PR:		206396
MFC after:	5 days
2016-01-22 14:52:31 +00:00
Warner Losh
3bdf775801 NO_MAN= has been deprecated in favor of MAN= for some time, go ahead
and finish the job. ncurses is now the only Makefile in the tree that
uses it since it wasn't a simple mechanical change, and will be
addressed in a future commit.
2014-04-13 05:21:56 +00:00
Konstantin Belousov
43648bc031 Remove dot at the end of errx() message.
Noted by:	bde
MFC after:	3 days
2010-03-14 13:29:09 +00:00
Konstantin Belousov
6e2e67160e Adjust style, fix typo, do not print errno because it is meaningless there.
This test fails for now.

MFC after:	3 days
2010-03-14 13:05:48 +00:00
David Xu
323d80a0a7 Don't forget to use fourth argument if O_CREAT is set in argument oflag.
The fourth specifies initial value for the semaphore.
2010-01-07 04:15:49 +00:00
David Xu
3df967d55c Add test code for POSIX semaphore implementation. 2010-01-05 12:34:13 +00:00