In article <[email protected]>,
Maxime Villard  <[email protected]> wrote:
>Hi,
>here is a small patch for ftpd.
>
>1. If one of these stat() fail, st1 and/or st2 are not initialized.

Yes, good catch, fixed.

>2. Since fatal() calls _exit(), 'ng' is useless.

In practice since people cargo-cult code it is better to have the
        ng = realloc(g, size);
pattern around rather than the:
        g = realloc(g, size);
pattern, which loses track of g's allocated memory.

>3. 'b' will be defined in the if{}/elseif{}/else{}.

Yup, removed.

>4. 'errno' is already initialized above.

I am a bit torn on this one, so I will leave it as it is. strtol()
is one of those bogus functions that require errno initialization,
so for clarity I think it should stay.

christos

Reply via email to