NL_TEXTMAX == INT_MAX?
H . J . Lu
hjl@lucon.org
Tue May 16 20:18:00 GMT 2000
On Tue, May 16, 2000 at 08:10:57PM -0700, Geoff Keating wrote:
> > Date: Tue, 16 May 2000 17:24:23 -0700
> > From: "H . J . Lu" <hjl@lucon.org>
>
> > char msg [NL_TEXTMAX];
>
> Such programs are broken. It's just like the same thing with
> PATH_MAX.
With PATH_MAX, I would expect I could create a pathname length up to
PATH_MAX.
>
> > I won't buy you can create a message with INT_MAX bytes.
>
> I expect on an Alpha you can... and will it really help if NL_TEXTMAX
> is, say, (1 << 30)?
Yes, it may be reasonable, which I doubt, for 64bit machines if you
have enough memory and/or swap space. But I won't call it reasonable
for 32bit machines. If you think it is reasonable, try to generate such
a message on both 64bit and 32bit machines.
H.J.
More information about the Libc-hacker
mailing list