Zsh Mailing List Archive
Messages sorted by:
Reverse Date,
Date,
Thread,
Author
Re: Problems building zsh on QNX 6.1
- X-seq: zsh-workers 17285
- From: "David Wolfe" <dwolfe@xxxxxxxxxxxxxx>
- To: <zsh-workers@xxxxxxxxxx>
- Subject: Re: Problems building zsh on QNX 6.1
- Date: Tue, 4 Jun 2002 17:00:49 -0400
- Mailing-list: contact zsh-workers-help@xxxxxxxxxx; run by ezmlm
- Organization: gForce Technologies, Inc.
> ... RLIMIT_RSS and RLIMIT_VMEM are both expanding to '6'.
Hmm. I was curious about this, so I checked <sys/resource.h> on QNX 6.1:
#define RLIMIT_AS 6 /* Limit on address space size. */
#define RLIMIT_VMEM RLIMIT_AS
#define RLIMIT_RSS RLIMIT_AS
RLIMIT_VMEM, RLIMIT_RSS and RLIMIT_AS are all identical. I'm guessing
this is because QNX is a realtime OS and doesn't limit how much memory
one process is allowed to use?
Anyway, I decided to roll up my sleeves and take a crack at fixing this.
It turns out that someone else had already done all the work! I merely
copied a few lines down to where they needed to go.
I humbly submit the following patch. (Please reply directly with
any comments, as I'm not subscribed to the list...)
- Dave
*** rlimits.c Tue Jun 4 16:23:08 2002
--- rlimits.c.new Tue Jun 4 16:27:52 2002
*************** bin_ulimit(char *name, char **argv, char
*** 565,571 ****
# ifdef RLIMIT_MEMLOCK
case RLIMIT_MEMLOCK:
# endif /* RLIMIT_MEMLOCK */
! # ifdef RLIMIT_VMEM
case RLIMIT_VMEM:
# endif /* RLIMIT_VMEM */
# ifdef RLIMIT_AIO_MEM
--- 565,573 ----
# ifdef RLIMIT_MEMLOCK
case RLIMIT_MEMLOCK:
# endif /* RLIMIT_MEMLOCK */
! /* If RLIMIT_VMEM and RLIMIT_RSS are defined and equal, avoid *
! * duplicate case statement. Observed on QNX Neutrino 6.1.0. */
! # if defined(RLIMIT_VMEM) && (!defined(RLIMIT_RSS) || RLIMIT_RSS !=
RLIMIT_VMEM)
case RLIMIT_VMEM:
# endif /* RLIMIT_VMEM */
# ifdef RLIMIT_AIO_MEM
Messages sorted by:
Reverse Date,
Date,
Thread,
Author