mirror of
git://git.code.sf.net/p/zsh/code
synced 2025-09-19 03:31:14 +02:00
44710: support RLIMIT_UMTXP on FreeBSD
This commit is contained in:
parent
3da3fe770a
commit
b82c24801f
4 changed files with 16 additions and 0 deletions
|
@ -1,5 +1,8 @@
|
||||||
2019-08-28 Jun-ichi Takimoto <takimoto-j@kba.biglobe.ne.jp>
|
2019-08-28 Jun-ichi Takimoto <takimoto-j@kba.biglobe.ne.jp>
|
||||||
|
|
||||||
|
* 44710: Src/Builtins/rlimits.awk, Src/Builtins/rlimits.c,
|
||||||
|
configure.ac: support RLIMIT_UMTXP on FreeBSD
|
||||||
|
|
||||||
* 44709: Src/zsh_system.h: incluce sys/capability.h only if
|
* 44709: Src/zsh_system.h: incluce sys/capability.h only if
|
||||||
HAVE_CAP_GET_PROC is defined
|
HAVE_CAP_GET_PROC is defined
|
||||||
|
|
||||||
|
|
|
@ -59,6 +59,7 @@ BEGIN {limidx = 0}
|
||||||
if (limnam == "NPTS") { msg[limnum] = "Npseudoterminals" }
|
if (limnam == "NPTS") { msg[limnum] = "Npseudoterminals" }
|
||||||
if (limnam == "SWAP") { msg[limnum] = "Mswapsize" }
|
if (limnam == "SWAP") { msg[limnum] = "Mswapsize" }
|
||||||
if (limnam == "KQUEUES") { msg[limnum] = "Nkqueues" }
|
if (limnam == "KQUEUES") { msg[limnum] = "Nkqueues" }
|
||||||
|
if (limnam == "UMTXP") { msg[limnum] = "Numtxp" }
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -413,6 +413,12 @@ printulimit(char *nam, int lim, int hard, int head)
|
||||||
printf("-k: kqueues ");
|
printf("-k: kqueues ");
|
||||||
break;
|
break;
|
||||||
# endif /* HAVE_RLIMIT_KQUEUES */
|
# endif /* HAVE_RLIMIT_KQUEUES */
|
||||||
|
# ifdef HAVE_RLIMIT_UMTXP
|
||||||
|
case RLIMIT_UMTXP:
|
||||||
|
if (head)
|
||||||
|
printf("-o: umtx shared locks ");
|
||||||
|
break;
|
||||||
|
# endif /* HAVE_RLIMIT_UMTXP */
|
||||||
default:
|
default:
|
||||||
if (head)
|
if (head)
|
||||||
printf("-N %2d: ", lim);
|
printf("-N %2d: ", lim);
|
||||||
|
@ -894,6 +900,11 @@ bin_ulimit(char *name, char **argv, UNUSED(Options ops), UNUSED(int func))
|
||||||
case 'T':
|
case 'T':
|
||||||
res = RLIMIT_PTHREAD;
|
res = RLIMIT_PTHREAD;
|
||||||
break;
|
break;
|
||||||
|
# endif
|
||||||
|
# ifdef HAVE_RLIMIT_UMTXP
|
||||||
|
case 'o':
|
||||||
|
res = RLIMIT_UMTXP;
|
||||||
|
break;
|
||||||
# endif
|
# endif
|
||||||
default:
|
default:
|
||||||
/* unrecognised limit */
|
/* unrecognised limit */
|
||||||
|
|
|
@ -1880,6 +1880,7 @@ zsh_LIMIT_PRESENT(RLIMIT_POSIXLOCKS)
|
||||||
zsh_LIMIT_PRESENT(RLIMIT_NPTS)
|
zsh_LIMIT_PRESENT(RLIMIT_NPTS)
|
||||||
zsh_LIMIT_PRESENT(RLIMIT_SWAP)
|
zsh_LIMIT_PRESENT(RLIMIT_SWAP)
|
||||||
zsh_LIMIT_PRESENT(RLIMIT_KQUEUES)
|
zsh_LIMIT_PRESENT(RLIMIT_KQUEUES)
|
||||||
|
zsh_LIMIT_PRESENT(RLIMIT_UMTXP)
|
||||||
|
|
||||||
AH_TEMPLATE([RLIMIT_VMEM_IS_RSS],
|
AH_TEMPLATE([RLIMIT_VMEM_IS_RSS],
|
||||||
[Define to 1 if RLIMIT_VMEM and RLIMIT_RSS both exist and are equal.])
|
[Define to 1 if RLIMIT_VMEM and RLIMIT_RSS both exist and are equal.])
|
||||||
|
|
Loading…
Reference in a new issue