aboutsummaryrefslogtreecommitdiff
path: root/shell
diff options
context:
space:
mode:
Diffstat (limited to 'shell')
-rw-r--r--shell/shell_common.c22
1 files changed, 19 insertions, 3 deletions
diff --git a/shell/shell_common.c b/shell/shell_common.c
index cc518d54b..da3165329 100644
--- a/shell/shell_common.c
+++ b/shell/shell_common.c
@@ -344,6 +344,9 @@ static const struct limits limits_tbl[] = {
{ RLIMIT_NICE, 0, "scheduling priority" }, // -e
{ RLIMIT_FSIZE, 9, "file size (blocks)" }, // -f
#define LIMIT_F_IDX 3
+#ifdef RLIMIT_SIGPENDING
+ { RLIMIT_SIGPENDING, 0, "pending signals" }, // -i
+#endif
#ifdef RLIMIT_MEMLOCK
{ RLIMIT_MEMLOCK, 10, "max locked memory (kb)" }, // -l
#endif
@@ -353,6 +356,9 @@ static const struct limits limits_tbl[] = {
#ifdef RLIMIT_NOFILE
{ RLIMIT_NOFILE, 0, "open files" }, // -n
#endif
+#ifdef RLIMIT_MSGQUEUE
+ { RLIMIT_MSGQUEUE, 0, "POSIX message queues (bytes)" }, // -q
+#endif
#ifdef RLIMIT_RTPRIO
{ RLIMIT_RTPRIO, 0, "real-time priority" }, // -r
#endif
@@ -372,16 +378,17 @@ static const struct limits limits_tbl[] = {
{ RLIMIT_LOCKS, 0, "file locks" }, // -x
#endif
};
-// bash also has these:
-//pending signals (-i) 61858 //RLIMIT_SIGPENDING
+// bash also shows:
//pipe size (512 bytes, -p) 8
-//POSIX message queues (bytes, -q) 819200 //RLIMIT_MSGQUEUE
static const char limit_chars[] ALIGN1 =
"c"
"d"
"e"
"f"
+#ifdef RLIMIT_SIGPENDING
+ "i"
+#endif
#ifdef RLIMIT_MEMLOCK
"l"
#endif
@@ -391,6 +398,9 @@ static const char limit_chars[] ALIGN1 =
#ifdef RLIMIT_NOFILE
"n"
#endif
+#ifdef RLIMIT_MSGQUEUE
+ "q"
+#endif
#ifdef RLIMIT_RTPRIO
"r"
#endif
@@ -417,6 +427,9 @@ static const char ulimit_opt_string[] ALIGN1 = "-HSa"
"d::"
"e::"
"f::"
+#ifdef RLIMIT_SIGPENDING
+ "i::"
+#endif
#ifdef RLIMIT_MEMLOCK
"l::"
#endif
@@ -426,6 +439,9 @@ static const char ulimit_opt_string[] ALIGN1 = "-HSa"
#ifdef RLIMIT_NOFILE
"n::"
#endif
+#ifdef RLIMIT_MSGQUEUE
+ "q::"
+#endif
#ifdef RLIMIT_RTPRIO
"r::"
#endif