From 4af4bb340eaa2b7a7fe34c36b6b9c6da29a1eec0 Mon Sep 17 00:00:00 2001 From: Thomas White Date: Fri, 28 Aug 2020 11:22:17 +0200 Subject: Insist on a job name --- src/gui_index.c | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/src/gui_index.c b/src/gui_index.c index ebb0b54d..f989b538 100644 --- a/src/gui_index.c +++ b/src/gui_index.c @@ -158,6 +158,11 @@ static void index_all_response_sig(GtkWidget *dialog, gint resp, job_title = gtk_entry_get_text(GTK_ENTRY(njp->job_title_entry)); job_notes = get_all_text(GTK_TEXT_VIEW(njp->job_notes_text)); + if ( job_title[0] == '\0' ) { + ERROR("You must provide a job name.\n"); + return; + } + free(njp->proj->indexing_new_job_title); njp->proj->indexing_new_job_title = strdup(job_title); -- cgit v1.2.3