From 85360e74b094028024bb65c2f2b4e836afc1dae4 Mon Sep 17 00:00:00 2001 From: Jari Vetoniemi Date: Sun, 24 Feb 2019 13:34:28 +0200 Subject: memview: NULL on empty input --- src/memview.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/memview.c b/src/memview.c index 2d11cb7..c639099 100644 --- a/src/memview.c +++ b/src/memview.c @@ -737,7 +737,7 @@ input(const char *prompt) } out: - return ctx.input.data; + return (strlen(ctx.input.data) ? ctx.input.data : NULL); } static void -- cgit v1.2.3