Re: [PATCH] change exit status of env(1)

2010-07-24 Thread Philip Guenther
On Thu, Jul 22, 2010 at 9:11 PM, Ted Unangst wrote: > On Thu, Jul 22, 2010 at 6:52 PM, Daniel Dickman wrote: >> sure. let me try. the problem is that right now i think env on OpenBSD >> can return 4 ambiguous values: 0, 1, 126, 127. if any of these values >> are returned i don't think it's possib

Re: [PATCH] change exit status of env(1)

2010-07-22 Thread Jason McIntyre
On Thu, Jul 22, 2010 at 06:52:00PM -0400, Daniel Dickman wrote: > > sure. let me try. the problem is that right now i think env on OpenBSD > can return 4 ambiguous values: 0, 1, 126, 127. if any of these values > are returned i don't think it's possible to know if the value was > returned from env

Re: [PATCH] change exit status of env(1)

2010-07-22 Thread Ted Unangst
On Thu, Jul 22, 2010 at 6:52 PM, Daniel Dickman wrote: > sure. let me try. the problem is that right now i think env on OpenBSD > can return 4 ambiguous values: 0, 1, 126, 127. if any of these values > are returned i don't think it's possible to know if the value was > returned from env itself or

Re: [PATCH] change exit status of env(1)

2010-07-22 Thread Daniel Dickman
On Thu, Jul 22, 2010 at 6:15 PM, Jason McIntyre wrote: > On Thu, Jul 22, 2010 at 05:38:29PM -0400, Daniel Dickman wrote: >> >> I think the man page is bit confusing. Note that I sent jmc@ the patch >> below for the man page to try to clear things up a bit there as well. The >> main point is that 1

Re: [PATCH] change exit status of env(1)

2010-07-22 Thread Jason McIntyre
On Thu, Jul 22, 2010 at 05:38:29PM -0400, Daniel Dickman wrote: > > I think the man page is bit confusing. Note that I sent jmc@ the patch > below for the man page to try to clear things up a bit there as well. The > main point is that 1-125 is an error range reserved for any errors that > happ

Re: [PATCH] change exit status of env(1)

2010-07-22 Thread Daniel Dickman
Hi Ingo, Thanks for taking a look. > > exit 126 means "utility was found but could not be invoked". > > exit 1-125 means some other error in env(1) > > Not quite; the -current manual says: > > 1-125 utility was invoked but failed in some way; see its manual page > for more informati

Re: [PATCH] change exit status of env(1)

2010-07-22 Thread Ingo Schwarze
Hi Daniel, Daniel Dickman wrote on Thu, Jul 22, 2010 at 04:47:59PM -0400: > exit 126 means "utility was found but could not be invoked". > exit 1-125 means some other error in env(1) Not quite; the -current manual says: 1-125 utility was invoked but failed in some way; see its manual page

[PATCH] change exit status of env(1)

2010-07-22 Thread Daniel Dickman
exit 126 means "utility was found but could not be invoked". exit 1-125 means some other error in env(1) So change 2 places to return an exit code of 125 instead. Index: env.c === RCS file: /usr/cvs/src/usr.bin/env/env.c,v retrieving