SPDX-FileCopyrightText: 2025 Alyssa Ross SPDX-License-Identifier: ISC diff --git a/doc/s6-softlimit.html b/doc/s6-softlimit.html index 05701ce..49a5b40 100644 --- a/doc/s6-softlimit.html +++ b/doc/s6-softlimit.html @@ -28 +28 @@ s6-softlimit changes its process limits, then executes into another program. - s6-softlimit [ -H | -h ] [ -a allmem ] [ -c core ] [ -d data ] [ -f fsize ] [ -l lock ] [ -m mem ] [ -o ofiles ] [ -p proc ] [ -r res ] [ -s stack ] [ -t cpusecs ] prog... + s6-softlimit [ -H | -h ] [ -a allmem ] [ -c core ] [ -d data ] [ -f fsize ] [ -l lock ] [ -m mem ] [ -o ofiles ] [ -P prio ] [ -p proc ] [ -r res ] [ -s stack ] [ -t cpusecs ] prog... @@ -60,0 +61 @@ and s6-softlimit will die. There is virtually no reason to ever use this. +
  • -P prio : limit the real-time priority to prio.
  • diff --git a/src/daemontools-extras/s6-softlimit.c b/src/daemontools-extras/s6-softlimit.c index d6112b2..beb7325 100644 --- a/src/daemontools-extras/s6-softlimit.c +++ b/src/daemontools-extras/s6-softlimit.c @@ -44 +44 @@ int main (int argc, char const *const *argv) - int opt = subgetopt_r(argc, argv, "hHa:c:d:f:l:m:o:p:r:s:t:", &l) ; + int opt = subgetopt_r(argc, argv, "hHa:c:d:f:l:m:o:P:p:r:s:t:", &l) ; @@ -105,0 +106,5 @@ int main (int argc, char const *const *argv) +#endif + break ; + case 'P' : +#ifdef RLIMIT_RTPRIO + doit(RLIMIT_RTPRIO, l.arg) ;