From bee366a9ca8a9f8eb490fd199fed74af81cfc56d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Fabiano=20Fid=C3=AAncio?= Date: Thu, 19 Dec 2019 09:45:52 +0100 Subject: [PATCH] tools: Don't check the output of virGetUserCacheDirectory() MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit virGetUserCacheDirectory() *never* *ever* returns NULL, making the checks for it completely unnecessary. Signed-off-by: Fabiano Fidêncio Reviewed-by: Ján Tomko --- tools/vsh.c | 5 ----- 1 file changed, 5 deletions(-) diff --git a/tools/vsh.c b/tools/vsh.c index bbb6227130..b982aeb359 100644 --- a/tools/vsh.c +++ b/tools/vsh.c @@ -2913,11 +2913,6 @@ vshReadlineInit(vshControl *ctl) */ userdir = virGetUserCacheDirectory(); - if (userdir == NULL) { - vshError(ctl, "%s", _("Could not determine home directory")); - goto cleanup; - } - ctl->historydir = g_strdup_printf("%s/%s", userdir, ctl->name); ctl->historyfile = g_strdup_printf("%s/history", ctl->historydir);