All of lore.kernel.org
 help / color / mirror / Atom feed
* Patch for restorecond to not report an error if filesystem does not support XATTR
@ 2006-11-29 22:18 Daniel J Walsh
  2006-11-30 16:25 ` Joshua Brindle
  2006-12-06 17:19 ` Karl MacMillan
  0 siblings, 2 replies; 9+ messages in thread
From: Daniel J Walsh @ 2006-11-29 22:18 UTC (permalink / raw)
  To: Stephen Smalley, Joshua Brindle, SE Linux

[-- Attachment #1: Type: text/plain, Size: 34 bytes --]

Caused by NFS Home directories.



[-- Attachment #2: restorecond-eopnotsupp.patch --]
[-- Type: text/x-patch, Size: 1108 bytes --]

diff --exclude-from=exclude --exclude POTFILES.in --exclude='*.po' --exclude='*.pot' -N -u -r nsapolicycoreutils/restorecond/restorecond.c policycoreutils-1.33.5/restorecond/restorecond.c
--- nsapolicycoreutils/restorecond/restorecond.c	2006-11-16 17:14:28.000000000 -0500
+++ policycoreutils-1.33.5/restorecond/restorecond.c	2006-11-29 12:44:06.000000000 -0500
@@ -210,9 +210,10 @@
 			}
 
 			if (fsetfilecon(fd, scontext) < 0) {
-				syslog(LOG_ERR,
-				       "set context %s->%s failed:'%s'\n",
-				       filename, scontext, strerror(errno));
+				if (errno != EOPNOTSUPP) 
+					syslog(LOG_ERR,
+					       "set context %s->%s failed:'%s'\n",
+					       filename, scontext, strerror(errno));
 				if (retcontext >= 0)
 					free(prev_context);
 				free(scontext);
@@ -225,8 +226,9 @@
 		if (retcontext >= 0)
 			free(prev_context);
 	} else {
-		syslog(LOG_ERR, "get context on %s failed: '%s'\n",
-		       filename, strerror(errno));
+		if (errno != EOPNOTSUPP) 
+			syslog(LOG_ERR, "get context on %s failed: '%s'\n",
+			       filename, strerror(errno));
 	}
 	free(scontext);
 	close(fd);

^ permalink raw reply	[flat|nested] 9+ messages in thread

end of thread, other threads:[~2006-12-12 18:18 UTC | newest]

Thread overview: 9+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2006-11-29 22:18 Patch for restorecond to not report an error if filesystem does not support XATTR Daniel J Walsh
2006-11-30 16:25 ` Joshua Brindle
2006-11-30 17:06   ` Daniel J Walsh
2006-11-30 18:15     ` Joshua Brindle
2006-11-30 19:02       ` Stephen Smalley
2006-12-02  3:37         ` Joshua Brindle
2006-12-04 20:10           ` Stephen Smalley
2006-12-06 17:19 ` Karl MacMillan
2006-12-12 18:18   ` Stephen Smalley

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.