From 12f5676cce3b2e04668df3f18f94f1a3c7fdbb9e Mon Sep 17 00:00:00 2001 From: Denis Vlasenko Date: Thu, 12 Oct 2006 06:15:13 +0000 Subject: [PATCH] execable: no need to check getenv for NULL, it works anyway. --- libbb/execable.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/libbb/execable.c b/libbb/execable.c index cb56b9181..817c06736 100644 --- a/libbb/execable.c +++ b/libbb/execable.c @@ -27,7 +27,7 @@ char *find_execable(const char *filename) { char *path, *p, *n; - p = path = xstrdup(getenv("PATH") ? : ""); + p = path = xstrdup(getenv("PATH")); while (p) { n = strchr(p, ':'); if (n) @@ -59,4 +59,3 @@ int exists_execable(const char *filename) } return 0; } - -- 2.25.1