Jakub Filak <[email protected]> writes:

> On Wednesday 25 of July 2012 14:57:19 Denys Vlasenko wrote:
>> On 07/20/2012 04:02 PM, Jakub Filak wrote:
>> > Signed-off-by: Jakub Filak <[email protected]>
>> > ---
>> > 
>> >  src/gui-wizard-gtk/wizard.c |    8 +++++++-
>> >  src/plugins/ureport.c       |    4 ++--
>> >  2 files changed, 9 insertions(+), 3 deletions(-)
>> > 
>> > diff --git a/src/gui-wizard-gtk/wizard.c b/src/gui-wizard-gtk/wizard.c
>> > index c93ff42..8591cad 100644
>> > --- a/src/gui-wizard-gtk/wizard.c
>> > +++ b/src/gui-wizard-gtk/wizard.c
>> > @@ -1300,6 +1300,13 @@ static void run_event_gtk_error(const char
>> > *error_line, void *param)> 
>> >  static char *run_event_gtk_logging(char *log_line, void *param)
>> >  {
>> >  
>> >      update_command_run_log(log_line, (struct analyze_event_data *)param);
>> > 
>> > +
>> > +    if (!strcmp(log_line, "THANKYOU"))
>> 
>> I still find this methid of writing string comparisons unreadable.
>> 
>>       strcmp(log_line, "THANKYOU") == 0
>
>
> string equality comparison utilizing strcmp() is unreadable in any form for 
> me 
> :)
> anyway, I'll try to write "strcmp() =="
> (I'm adding a rule to my check code style script ;))

Coccinelle is a program matching and transformation engine which
provides the language SmPL (Semantic Patch Language) for specifying
desired matches and transformations in C code.

http://coccinelle.lip6.fr/ is your the best friend for that job ;)

-- 
Nikola

Reply via email to