This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
Re: [lto][patch] Use @args when calling lto-wrapper
Diego Novillo wrote:
> On Thu, Jan 29, 2009 at 07:57, Rafael Espindola <espindola@google.com> wrote:
>
>> @@ -362,15 +362,40 @@ exec_lto_wrapper (char *const argv[])
>> int pipe_read;
>> int pipe_write;
>> int t;
>> + const int name_size = 100;
>> + char *at_args;
>> + char *args_name;
>> + FILE *args;
>> + int i;
>> +
>> + /* Write argv to a file to avoid a command line that is too long. */
>> + at_args = malloc (name_size);
>
> name_size + 1
In fact you can just use asprintf.
Paolo