Re: [hackers] [sbase] Audit printenv(1) || FRIGN

From: FRIGN <dev_AT_frign.de>
Date: Mon, 2 Mar 2015 14:27:20 +0100

On Sun, 1 Mar 2015 08:01:18 +0100
"Roberto E. Vargas Caballero" <k0ga_AT_shike2.com> wrote:

> In this case I agree with Evan, and I see the argv loop idiomatic.
> I have seen in several books and in diferent sources. I usually
> do the argv loop:
>
> for (++argv; *argv; ++argc)
>
> or
>
> while (*++argv)
>
> and if I need do a test argc > something then I update the value of argc
> in the body. If I only need argc > 0 I use *argv != 0.

Check out this new commit, I reflected your ideas. Checking argv is more
consistent across sbase:

http://git.2f30.org/sbase/commit/?id=286df29e7d78ae4a6b4474bb14d517e02e4f0489

Cheers

FRIGN

-- 
FRIGN <dev_AT_frign.de>
Received on Mon Mar 02 2015 - 14:27:20 CET

This archive was generated by hypermail 2.3.0 : Mon Mar 02 2015 - 14:36:08 CET