Re: ARG_MAX/E2BIG and environment size
From: Barry Margolin (barmar_at_alum.mit.edu)
Date: 12/17/03
- Next message: Måns Rullgård: "Re: exiting chroot()"
- Previous message: Måns Rullgård: "Re: exiting chroot()"
- In reply to: Mohun Biswas: "ARG_MAX/E2BIG and environment size"
- Next in thread: Casper H.S. Dik: "Re: ARG_MAX/E2BIG and environment size"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
Date: Wed, 17 Dec 2003 18:03:21 GMT
In article <b6_Db.135922$_M.692067@attbi_s54>,
Mohun Biswas <m.biswas@invalid.addr> wrote:
> Standard Unix documentation (e.g. "man execve") states that E2BIG is
> returned if an exec fails because the combined length of the argument
> list and the environment is greater than ARG_MAX. Fine. But I can't see
> where the term "the environment" is defined. In particular, does it
> refer to the total size of the values alone? Or do the names count too?
> What about the '=' signs and terminating nulls - are they represented
> literally in the environment block and thus need to be counted?
The environment is one big block containing all the names, values, equal
signs, and nulls in between each value. It's the total size of all this
that matters.
-- Barry Margolin, barmar@alum.mit.edu Woburn, MA
- Next message: Måns Rullgård: "Re: exiting chroot()"
- Previous message: Måns Rullgård: "Re: exiting chroot()"
- In reply to: Mohun Biswas: "ARG_MAX/E2BIG and environment size"
- Next in thread: Casper H.S. Dik: "Re: ARG_MAX/E2BIG and environment size"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
Relevant Pages
|