From 48b94d71c778969db243a1318995fc8c4570ea1d Mon Sep 17 00:00:00 2001 From: Benno Schulenberg Date: Mon, 14 Oct 2019 19:17:28 +0200 Subject: [PATCH] tweaks: pass an empty string for copying instead of a non-existent one --- src/search.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/search.c b/src/search.c index 228b0b84..6e39d3a3 100644 --- a/src/search.c +++ b/src/search.c @@ -76,7 +76,7 @@ void search_init(bool replacing, bool keep_the_answer) /* When starting a new search, clear the current answer. */ if (!keep_the_answer) - answer = mallocstrcpy(answer, NULL); + answer = mallocstrcpy(answer, ""); /* If something was searched for earlier, include it in the prompt. */ if (*last_search != '\0') {