summaryrefslogtreecommitdiff
path: root/src/install.c
diff options
context:
space:
mode:
authorJim Meyering <jim@meyering.net>2007-06-23 10:11:25 +0200
committerJim Meyering <jim@meyering.net>2007-06-23 10:11:25 +0200
commit519d7a95a3f8103925aa84f9bdef326ce88d37cc (patch)
treec4a82988e9651e115fa1c2cccc6227cb136de4fa /src/install.c
parenta0304574e96916f0444b04f301f8e5191615f800 (diff)
downloadcoreutils-519d7a95a3f8103925aa84f9bdef326ce88d37cc.tar.xz
Prefer "STREQ (a, b)" over "strcmp (a, b) == 0"; similar for != 0.
* src/base64.c (main): Likewise. * src/install.c (setdefaultfilecon): Likewise. * src/sort.c (main): Likewise. * Makefile.maint (sc_prohibit_strcmp): New rule. * .x-sc_prohibit_strcmp: New file, to list the few exceptions. * Makefile.am (EXTRA_DIST): Add .x-sc_prohibit_strcmp.
Diffstat (limited to 'src/install.c')
-rw-r--r--src/install.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/install.c b/src/install.c
index 39d514957..566c93c4d 100644
--- a/src/install.c
+++ b/src/install.c
@@ -217,7 +217,7 @@ setdefaultfilecon (char const *file)
/* If there's an error determining the context, or it has none,
return to allow default context */
if ((matchpathcon (file, st.st_mode, &scontext) != 0) ||
- (strcmp (scontext, "<<none>>") == 0))
+ STREQ (scontext, "<<none>>"))
{
if (scontext != NULL)
freecon (scontext);