diff options
author | 1998-11-24 04:32:47 +0000 | |
---|---|---|
committer | 1998-11-24 04:32:47 +0000 | |
commit | 333dac4a2963508e3c0f71c43eccb7e56f3a20a3 (patch) | |
tree | 1be5aea85be2a7f41af7cdb17bfb8d8b87197675 | |
parent | deal with busses which misidentify; enami@netbsd (diff) | |
download | wireguard-openbsd-333dac4a2963508e3c0f71c43eccb7e56f3a20a3.tar.xz wireguard-openbsd-333dac4a2963508e3c0f71c43eccb7e56f3a20a3.zip |
better error message from ulimit
-rw-r--r-- | bin/ksh/c_ulimit.c | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/bin/ksh/c_ulimit.c b/bin/ksh/c_ulimit.c index 153e68d0f79..0faf8fbfa66 100644 --- a/bin/ksh/c_ulimit.c +++ b/bin/ksh/c_ulimit.c @@ -1,4 +1,4 @@ -/* $OpenBSD: c_ulimit.c,v 1.5 1998/10/29 04:09:20 millert Exp $ */ +/* $OpenBSD: c_ulimit.c,v 1.6 1998/11/24 04:32:47 millert Exp $ */ /* ulimit -- handle "ulimit" builtin @@ -227,7 +227,11 @@ c_ulimit(wp) if (how & HARD) limit.rlim_max = val; if (setrlimit(l->scmd, &limit) < 0) { - bi_errorf("bad limit: %s", strerror(errno)); + if (errno == EPERM) + bi_errorf("exceeds allowable limit"); + else + bi_errorf("bad limit: %s", + strerror(errno)); return 1; } } else { |