# HG changeset patch # User Richard Laager # Date 1141697519 0 # Node ID d6530e0cd89fb4a7fa00bbfe2597b839acf55845 # Parent 3e9c865abd3f814ac167afceef6f8a6dbb76d9c9 [gaim-migrate @ 15795] (19:58:46) faceprint: I don't think gtk_entry_get_text ever returns NULL (20:03:43) faceprint: i think the purpose of that if statement was to only do anything if they actually entered any text I've undone my previous changes and fixed the inner if...else if...else block to match. committer: Tailor Script diff -r 3e9c865abd3f -r d6530e0cd89f plugins/gevolution/new_person_dialog.c --- a/plugins/gevolution/new_person_dialog.c Tue Mar 07 02:09:05 2006 +0000 +++ b/plugins/gevolution/new_person_dialog.c Tue Mar 07 02:11:59 2006 +0000 @@ -104,7 +104,7 @@ lastname = gtk_entry_get_text(GTK_ENTRY(dialog->lastname)); email = gtk_entry_get_text(GTK_ENTRY(dialog->email)); - if (firstname != NULL || lastname != NULL) + if (*firstname || *lastname) { if (dialog->contact == NULL) { @@ -112,9 +112,9 @@ dialog->contact = e_contact_new(); - if (lastname != NULL && firstname != NULL) + if (*lastname && *firstname) file_as = g_strdup_printf("%s, %s", lastname, firstname); - else if (lastname != NULL) + else if (*lastname) file_as = g_strdup(lastname); else file_as = g_strdup(firstname);