* [PATCH] policycoreutils: 'fixfiles check' should not change anything
@ 2016-08-09 13:24 Petr Lautrbach
2016-08-09 20:24 ` James Carter
0 siblings, 1 reply; 2+ messages in thread
From: Petr Lautrbach @ 2016-08-09 13:24 UTC (permalink / raw)
To: selinux
-n was not being passed down to restorecon properly in the code path
for -C and -N
Patch-by: Dan Callaghan <dcallagh@redhat.com>
Signed-off-by: Petr Lautrbach <plautrba@redhat.com>
---
policycoreutils/scripts/fixfiles | 7 ++++---
1 file changed, 4 insertions(+), 3 deletions(-)
diff --git a/policycoreutils/scripts/fixfiles b/policycoreutils/scripts/fixfiles
index 5c29eb9..fa43a53 100755
--- a/policycoreutils/scripts/fixfiles
+++ b/policycoreutils/scripts/fixfiles
@@ -150,8 +150,9 @@ fi
#
newer() {
DATE=$1
+ shift
for m in `echo $FILESYSTEMSRW`; do
- find $m -mount -newermt $DATE -print0 2>/dev/null | ${RESTORECON} ${FORCEFLAG} ${VERBOSE} -i -0 -f -
+ find $m -mount -newermt $DATE -print0 2>/dev/null | ${RESTORECON} ${FORCEFLAG} ${VERBOSE} $* -i -0 -f -
done;
}
@@ -190,7 +191,7 @@ if [ -f ${PREFC} -a -x /usr/bin/diff ]; then
esac; \
fi; \
done | \
- ${RESTORECON} ${VERBOSE} -i -f - -R `exclude_dirs`; \
+ ${RESTORECON} ${VERBOSE} -i -f - -R $* `exclude_dirs`; \
rm -f ${TEMPFILE} ${PREFCTEMPFILE}
fi
}
@@ -222,7 +223,7 @@ if [ ! -z "$PREFC" ]; then
exit $?
fi
if [ ! -z "$BOOTTIME" ]; then
- newer $BOOTTIME
+ newer $BOOTTIME $*
exit $?
fi
[ -x /usr/sbin/genhomedircon ] && /usr/sbin/genhomedircon
--
1.8.3.1
^ permalink raw reply related [flat|nested] 2+ messages in thread
* Re: [PATCH] policycoreutils: 'fixfiles check' should not change anything
2016-08-09 13:24 [PATCH] policycoreutils: 'fixfiles check' should not change anything Petr Lautrbach
@ 2016-08-09 20:24 ` James Carter
0 siblings, 0 replies; 2+ messages in thread
From: James Carter @ 2016-08-09 20:24 UTC (permalink / raw)
To: Petr Lautrbach, selinux
On 08/09/2016 09:24 AM, Petr Lautrbach wrote:
> -n was not being passed down to restorecon properly in the code path
> for -C and -N
>
> Patch-by: Dan Callaghan <dcallagh@redhat.com>
> Signed-off-by: Petr Lautrbach <plautrba@redhat.com>
Applied.
Thanks,
Jim
> ---
> policycoreutils/scripts/fixfiles | 7 ++++---
> 1 file changed, 4 insertions(+), 3 deletions(-)
>
> diff --git a/policycoreutils/scripts/fixfiles b/policycoreutils/scripts/fixfiles
> index 5c29eb9..fa43a53 100755
> --- a/policycoreutils/scripts/fixfiles
> +++ b/policycoreutils/scripts/fixfiles
> @@ -150,8 +150,9 @@ fi
> #
> newer() {
> DATE=$1
> + shift
> for m in `echo $FILESYSTEMSRW`; do
> - find $m -mount -newermt $DATE -print0 2>/dev/null | ${RESTORECON} ${FORCEFLAG} ${VERBOSE} -i -0 -f -
> + find $m -mount -newermt $DATE -print0 2>/dev/null | ${RESTORECON} ${FORCEFLAG} ${VERBOSE} $* -i -0 -f -
> done;
>
> }
> @@ -190,7 +191,7 @@ if [ -f ${PREFC} -a -x /usr/bin/diff ]; then
> esac; \
> fi; \
> done | \
> - ${RESTORECON} ${VERBOSE} -i -f - -R `exclude_dirs`; \
> + ${RESTORECON} ${VERBOSE} -i -f - -R $* `exclude_dirs`; \
> rm -f ${TEMPFILE} ${PREFCTEMPFILE}
> fi
> }
> @@ -222,7 +223,7 @@ if [ ! -z "$PREFC" ]; then
> exit $?
> fi
> if [ ! -z "$BOOTTIME" ]; then
> - newer $BOOTTIME
> + newer $BOOTTIME $*
> exit $?
> fi
> [ -x /usr/sbin/genhomedircon ] && /usr/sbin/genhomedircon
>
--
James Carter <jwcart2@tycho.nsa.gov>
National Security Agency
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2016-08-09 20:24 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2016-08-09 13:24 [PATCH] policycoreutils: 'fixfiles check' should not change anything Petr Lautrbach
2016-08-09 20:24 ` James Carter
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.