From: Alex Deymo Date: Wed, 2 Jul 2014 05:52:32 +0000 (-0700) Subject: maint: fix context_t init warning on systems without selinux X-Git-Tag: v8.23~23 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=28d1dc525182c347f2346c52fa7b5ab4a9b1a148;p=thirdparty%2Fcoreutils.git maint: fix context_t init warning on systems without selinux On systems without libselinux, context_t is defined as an int type, but defined as a pointer type by SELinux. * src/chcon.c: Init with 0 rather than NULL to avoid warning. --- diff --git a/src/chcon.c b/src/chcon.c index e253a46390..cda06612fe 100644 --- a/src/chcon.c +++ b/src/chcon.c @@ -141,7 +141,7 @@ static int change_file_context (int fd, char const *file) { char *file_context = NULL; - context_t context IF_LINT (= NULL); + context_t context IF_LINT (= 0); char const * context_string; int errors = 0;