diff mbox

policycoreutils: setfiles: make -I imply -D

Message ID 1475252015-17100-1-git-send-email-sds@tycho.nsa.gov (mailing list archive)
State Not Applicable
Headers show

Commit Message

Stephen Smalley Sept. 30, 2016, 4:13 p.m. UTC
-I only makes sense if we are also enabling digests.

Signed-off-by: Stephen Smalley <sds@tycho.nsa.gov>
---
 policycoreutils/setfiles/setfiles.c | 1 +
 1 file changed, 1 insertion(+)
diff mbox

Patch

diff --git a/policycoreutils/setfiles/setfiles.c b/policycoreutils/setfiles/setfiles.c
index 22eba0f..1a2d711 100644
--- a/policycoreutils/setfiles/setfiles.c
+++ b/policycoreutils/setfiles/setfiles.c
@@ -279,6 +279,7 @@  int main(int argc, char **argv)
 		case 'I': /* Force label check by ignoring directory digest. */
 			r_opts.ignore_digest =
 					   SELINUX_RESTORECON_IGNORE_DIGEST;
+			request_digest = 1;
 			break;
 		case 'D': /*
 			   * Request file_contexts digest in selabel_open