mirror of
https://github.com/SELinuxProject/selinux
synced 2025-02-04 03:41:56 +00:00
Author: Daniel J Walsh
Email: dwalsh@redhat.com Subject: refpolicy: nsalibselinux_utils_matchpathcon.c changes Date: Tue, 07 Jul 2009 12:30:52 -0400 --text follows this line-- Signed-off-by: Joshua Brindle <method@manicmethod.com>
This commit is contained in:
parent
94c51ba3b1
commit
00f0d550d5
@ -22,9 +22,13 @@ int printmatchpathcon(char *path, int header, int mode)
|
||||
char *buf;
|
||||
int rc = matchpathcon(path, mode, &buf);
|
||||
if (rc < 0) {
|
||||
fprintf(stderr, "matchpathcon(%s) failed: %s\n", path,
|
||||
strerror(errno));
|
||||
return 1;
|
||||
if (errno == ENOENT) {
|
||||
buf=strdup("<<none>>");
|
||||
} else {
|
||||
fprintf(stderr, "matchpathcon(%s) failed: %s\n", path,
|
||||
strerror(errno));
|
||||
return 1;
|
||||
}
|
||||
}
|
||||
if (header)
|
||||
printf("%s\t%s\n", path, buf);
|
||||
|
Loading…
Reference in New Issue
Block a user