summaryrefslogtreecommitdiffstats
path: root/contrib/amd
diff options
context:
space:
mode:
authordim <dim@FreeBSD.org>2015-01-28 18:19:25 +0000
committerdim <dim@FreeBSD.org>2015-01-28 18:19:25 +0000
commit110aa2a0d09a6283b549938eabee76423a2e96f5 (patch)
treecce9f5536d56acc3036dbc7888f72418c38dae17 /contrib/amd
parent4d4e2ba1b411d23dca952f319f08a3a14dac4fc7 (diff)
downloadFreeBSD-src-110aa2a0d09a6283b549938eabee76423a2e96f5.zip
FreeBSD-src-110aa2a0d09a6283b549938eabee76423a2e96f5.tar.gz
Fix the following clang 3.6.0 warning in contrib/amd/hlfsd/homedir.c:
contrib/amd/hlfsd/homedir.c:497:8: error: address of array 'buf' will always evaluate to 'true' [-Werror,-Wpointer-bool-conversion] if (!buf || buf[0] == '\0') ~^~~ In the affected function, 'buf' is declared as an array of char, so it can never be null. Remove the unecessary check.
Diffstat (limited to 'contrib/amd')
-rw-r--r--contrib/amd/hlfsd/homedir.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/contrib/amd/hlfsd/homedir.c b/contrib/amd/hlfsd/homedir.c
index 2ade32f..fb4720c 100644
--- a/contrib/amd/hlfsd/homedir.c
+++ b/contrib/amd/hlfsd/homedir.c
@@ -494,7 +494,7 @@ readent:
buf[0] = '\0';
fgets(buf, 256, passwd_fp);
passwd_line++;
- if (!buf || buf[0] == '\0')
+ if (buf[0] == '\0')
goto readent;
/* read user name */
OpenPOWER on IntegriCloud