Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.zx2c4.com/cgit.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
path: root/cgit.c
diff options
context:
space:
mode:
authorJohn Keeping <john@keeping.me.uk>2015-10-09 01:23:56 +0300
committerJason A. Donenfeld <Jason@zx2c4.com>2015-10-09 11:54:19 +0300
commit94182d6031df0d956a94ecd7ece233e345468961 (patch)
treea3c8a484c5120038444175aa085006b39ee030f6 /cgit.c
parent978ce8c00c0d3117f6470a77b08aa0f97984604f (diff)
cgit.c: remove useless null check
Everywhere else in this function we do not check whether the value is null and parse_configfile() never passes a null value to this callback. Coverity-id: 13846 Signed-off-by: John Keeping <john@keeping.me.uk>
Diffstat (limited to 'cgit.c')
-rw-r--r--cgit.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/cgit.c b/cgit.c
index 28a2f14..5937b9e 100644
--- a/cgit.c
+++ b/cgit.c
@@ -110,7 +110,7 @@ static void config_cb(const char *name, const char *value)
ctx.repo->path = trim_end(value, '/');
else if (ctx.repo && starts_with(name, "repo."))
repo_config(ctx.repo, name + 5, value);
- else if (!strcmp(name, "readme") && value != NULL)
+ else if (!strcmp(name, "readme"))
string_list_append(&ctx.cfg.readme, xstrdup(value));
else if (!strcmp(name, "root-title"))
ctx.cfg.root_title = xstrdup(value);