[PATCH] Implement more export-options (clean, no-export-attributes)
Daniele Ricci
daniele.athome at gmail.com
Fri Jan 17 10:34:34 CET 2014
You're right, sorry. Fixing now.
On Fri, Jan 17, 2014 at 8:58 AM, Werner Koch <wk at gnupg.org> wrote:
> On Fri, 17 Jan 2014 00:10, daniele.athome at gmail.com said:
>> + a = realloc (a, sizeof *a + strlen (a->arg) + strlen (arg));
>> + if (!a)
>> + return gpg_error_from_syserror ();
>> +
>> + strcat (a->arg, arg);
>> +
>> + *gpg->argtail = a;
>> + gpg->argtail = &a->next;
>
> This assumes that realloc does not change the value of A. realloc may
> return a pointer to a different memory block. In turn the predecessor
> of the original A will have a dangling pointer.
>
>
>
> Shalom-Salam,
>
> Werner
>
> --
> Die Gedanken sind frei. Ausnahmen regelt ein Bundesgesetz.
>
--
Daniele
More information about the Gnupg-devel
mailing list