Use ENFILE errno instead of ENOMEM in pipespace()

2017-12-18 Thread Alexander Kuleshov
pipe()/pipe2() system calls may fail now with ENOMEM error during creation in pipe_create() -> pipespace(). The bellow diff replaces ENOMEM with ENFILE errno which is already documented for pipe()/pipe2() to decrease amount of possible errno(s) with similar behaviour. Index: sys_pipe.c ===

Re: Mention ENOMEM as as possible result of pipe()/pipe2()

2017-12-18 Thread Alexander Kuleshov
On Tue, Dec 19, 2017 at 1:04 AM, Mark Kettenis wrote: >> From: "Theo de Raadt" >> Date: Mon, 18 Dec 2017 11:57:32 -0700 >> >> I think kernel should be fixed to return ENFILE in that case. > > Was thinking the same thing. > On Tue, Dec 19, 2017 at 12:57 AM, Theo de Raadt wrote: > I think kernel

Mention ENOMEM as as possible result of pipe()/pipe2()

2017-12-18 Thread Alexander Kuleshov
Hello, pipe()/pipe2() may fail with ENOMEM error during creation in pipe_create() -> pipespace(), but it is not mentioned in the pipe(2) man page. The below diff fixes this. Index: pipe.2 === RCS file: /cvs/src/lib/libc/sys/pipe.2,v

fix a typo in roff(7)

2017-12-15 Thread Alexander Kuleshov
Hello, I've just noticed a little typo in the roff(7) man page (s/agument/argument). The diff is below. Index: roff.7 === RCS file: /cvs/src/share/man/man7/roff.7,v retrieving revision 1.74 diff -u -p -r1.74 roff.7 --- roff.7 5

[PATCH] sdiff: fix comparision between signed and unsiged warning

2017-05-31 Thread Alexander Kuleshov
This diff fixes edit.c: In function 'eparse': edit.c:149: warning: comparision between signed and unsigned warning during compilation. Index: usr.bin/sdiff/edit.c === RCS file: /cvs/src/usr.bin/sdiff/edit.c,v retrieving revision 1.2