This is the mail archive of the gdb-patches@sourceware.org mailing list for the GDB project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: [PATCH] Avoid "format not a string literal" warnings


On 04/13/2016 09:12 PM, Sergio Durigan Junior wrote:

>>    if (alias_argv[0] == NULL || command_argv[0] == NULL
>>        || *alias_argv[0] == '\0' || *command_argv[0] == '\0')
>> -    error (_(usage));
>> +    alias_usage_error ();
> 
> I'd call error directly here and above (and yes, replicate the message),
> but that is a matter of personal taste.

OOC, is there a reason for that preference?

Instead of replicating the message, I also thought of:

    error (("%s"), usage);

but it seems slightly nicer to me the way I wrote it ( obviously :-) ).

> LGTM.

Thanks,
Pedro Alves


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]