Svante Signell, le Sat 10 May 2014 18:18:23 +0200, a écrit :
> +     char *expfn;
> +     char *actfn;

You need to initialize them to NULL, so that this

> @@ -763,9 +768,11 @@
>  out:
>       if (*expfn && !clit_bit_fn_p(exp)) {
>               unlink(expfn);
> +             free(expfn);
>       }
>       if (*actfn) {
>               unlink(actfn);
> +             free(actfn);
>       }
>       return difftool;
>  }

properly tests as desired.

Also, why this:

> @@ -701,7 +706,7 @@
>  
>       case 0:;
>               /* i am the child */
> -             static char *const diff_opt[] = {
> +             char *diff_opt[] = {
>                       "diff",
>                       "-u",
>                       expfn, actfn, NULL,

Apart from that, it looks fine.

Samuel


-- 
To UNSUBSCRIBE, email to [email protected]
with a subject of "unsubscribe". Trouble? Contact [email protected]
Archive: 
https://lists.debian.org/[email protected]

Reply via email to