fetchmail-friends
[Top] [All Lists]

Re: [fetchmail][PATCH] general cleanup and anti-format-string patch

2001-06-24 15:27:52
Henrique de Moraes Holschuh <hmh(_at_)debian(_dot_)org>:
On Sun, 24 Jun 2001, Todd Sabin wrote:
Henrique de Moraes Holschuh <hmh(_at_)debian(_dot_)org> writes:
and changes lots of sprintfs to snprintf. Same for strcat -> strncat.

Your usage of strncat is wrong.  Don't feel bad, though; nearly
everyone misuses it the same way.  strncat is one of the worst
designed apis in existence.  I'd suggest not using it at all.

Changed them all to snprintf, which is safe and quite easily understood.
Thanks for the hint, strncat won't get me unaware again.

Patch against 5.8.8 WITH my previous bogus patch applied. Attached.

Accepted.
-- 
                <a href="http://www.tuxedo.org/~esr/";>Eric S. Raymond</a>

Rifles, muskets, long-bows and hand-grenades are inherently democratic
weapons.  A complex weapon makes the strong stronger, while a simple
weapon -- so long as there is no answer to it -- gives claws to the
weak.
        -- George Orwell, "You and the Atom Bomb", 1945