bug-coreutils
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: system.h cleanups


From: Eric Blake
Subject: Re: system.h cleanups
Date: Thu, 8 Oct 2009 15:24:21 +0000 (UTC)
User-agent: Loom/3.14 (http://gmane.org/)

Jim Meyering <jim <at> meyering.net> writes:

> 
> ??  As far as I can see, one cannot remove ASSIGN_STRDUPA,
> since it is not defined anyplace else.
> The code (cp.c, df.c, copy.c) won't compile without it.

Aargh.  Serves me right for deleting without testing.  I merely grepped for 
strdupa (no other uses) rather than ASSIGN_STRDUPA.  I've reverted that portion 
of the patch.  Although there's still the issue that ASSIGN_STRDUPA can cause 
stack overflow if used on arbitrarily long names; maybe it's worth rewriting 
these interfaces to use Bruno's malloca interfaces (alloca for short lengths, 
but malloc for long; requires adding a cleanup call, but still provides speed 
in the common case of short strings).

-- 
Eric Blake






reply via email to

[Prev in Thread] Current Thread [Next in Thread]