public inbox for linux-man@vger.kernel.org
 help / color / mirror / Atom feed
From: "G. Branden Robinson" <g.branden.robinson@gmail.com>
To: "Alejandro Colomar (man-pages)" <alx.manpages@gmail.com>
Cc: наб <nabijaczleweli@nabijaczleweli.xyz>,
	linux-man@vger.kernel.org,
	"Michael Kerrisk (man-pages)" <mtk.manpages@gmail.com>
Subject: Re: [PATCH v2 3/5] alloca.3: clarify reasoning for no error return in BUGS
Date: Wed, 29 Oct 2025 03:42:00 -0500	[thread overview]
Message-ID: <20251029084200.umuk2hbescz3txgn@illithid> (raw)
In-Reply-To: <4c862994-1fb7-7c45-8f0e-9a3bb8d76e13@gmail.com>

[-- Attachment #1: Type: text/plain, Size: 1573 bytes --]

Hi Alex,

At 2021-09-15T21:42:26+0200, Alejandro Colomar (man-pages) wrote:
> On 9/14/21 2:41 PM, наб wrote:
> >   .SH BUGS
> > -There is no error indication if the stack frame cannot be extended.
> > -(However, after a failed allocation, the program is likely to receive a
> > +Due to the nature of the stack, it is impossible to check if the allocation
> > +would overflow the space available, and, hence, neither is indicating an error.
> 
> I'm not sure this use of neither (without a preceding "not") is valid
> English.  Is it?

The sentence is confusingly cast, but the problem is not as simple as
you describe.  It is common in English to use "neither" without "not"
preceding or following.

Neither wolverines nor beavers have yet self-domesticated.
Neither C nor C++ are good language choices for novice programmers.

Maybe you were expecting something like this wording:

Due to the nature of the stack, checking if the allocation would
overflow the space available is not possible, and, hence, neither is
indicating an error.

That's more grammatically conventional.  However, I would recast even
more aggressively, as I find "due to the nature of the stack" hand-wavy.

I suggest something like:

alloca() does not query the system for available stack memory, and does
not fall back to using the heap if stack storage is unavailable.  It
therefore cannot indicate an error if the allocation fails.  If it does,
the system generates a SIGSEGV signal.

(I checked getrlimit(2) before composing that.)

Regards,
Branden

[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 833 bytes --]

  parent reply	other threads:[~2025-10-29  8:42 UTC|newest]

Thread overview: 33+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-08-23 21:01 [PATCH 1/2] strdup.3: drop mention of "the GNU GCC suite" наб
2021-08-23 21:01 ` [PATCH 2/2] alloca.3: rewrite NOTES наб
2021-08-24  9:50   ` Michael Kerrisk (man-pages)
2021-08-24 10:04     ` G. Branden Robinson
2021-08-24 11:58       ` наб
2021-08-24 10:33     ` Alejandro Colomar (man-pages)
2021-08-24 11:18       ` Alejandro Colomar (man-pages)
2021-08-25 18:21       ` наб
2021-08-24 11:47     ` наб
2021-08-24  9:21 ` [PATCH 1/2] strdup.3: drop mention of "the GNU GCC suite" Michael Kerrisk (man-pages)
2021-08-24 10:28   ` наб
2021-08-24 10:40     ` Alejandro Colomar (man-pages)
2021-09-14 12:40 ` [PATCH v2 0/5] alloca(3) commentary re-write наб
2021-09-14 12:40   ` [PATCH v2 1/5] strdup.3: drop mention of "the GNU GCC suite" наб
2021-09-15 19:49     ` Alejandro Colomar (man-pages)
2021-09-14 12:41   ` [PATCH v2 2/5] alloca.3: clarify origins in CONFORMING TO наб
2021-09-15 19:49     ` Alejandro Colomar (man-pages)
2021-09-14 12:41   ` [PATCH v2 3/5] alloca.3: clarify reasoning for no error return in BUGS наб
2021-09-15 19:42     ` Alejandro Colomar (man-pages)
2021-09-17 20:35       ` наб
2025-10-29  8:42       ` G. Branden Robinson [this message]
2025-10-29 10:15         ` Alejandro Colomar
2025-10-29 10:30           ` G. Branden Robinson
2025-10-29 10:58             ` Alejandro Colomar
2025-10-29 11:12               ` G. Branden Robinson
2025-10-29 11:23                 ` Alejandro Colomar
2025-10-29 15:22         ` наб
2025-10-29 22:55           ` G. Branden Robinson
2021-09-14 12:41   ` [PATCH v2 4/5] alloca.3: remove GCC faffling from NOTES наб
2021-09-15 19:48     ` Alejandro Colomar (man-pages)
2021-09-17 20:45       ` наб
2021-09-19 19:39         ` Alejandro Colomar (man-pages)
2021-09-14 12:41   ` [PATCH v2 5/5] alloca.3: simplfy malloc(3) suite comparison, note VLAs наб

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20251029084200.umuk2hbescz3txgn@illithid \
    --to=g.branden.robinson@gmail.com \
    --cc=alx.manpages@gmail.com \
    --cc=linux-man@vger.kernel.org \
    --cc=mtk.manpages@gmail.com \
    --cc=nabijaczleweli@nabijaczleweli.xyz \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox