From 0bc3ffeb7bd7f2cb1d0ba1ce65fdbaf87d67ecff Mon Sep 17 00:00:00 2001 From: Eric Kohl Date: Fri, 24 May 2013 09:50:49 +0000 Subject: [PATCH] [RTL] Comparison is always true due to limited range of data type. Patch by Samuel Serapion. CORE-7177 #resolve #comment Committed in r59076. svn path=/trunk/; revision=59076 --- reactos/lib/rtl/acl.c | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/reactos/lib/rtl/acl.c b/reactos/lib/rtl/acl.c index 40fbb4df0ef..cde5cd0d6bf 100644 --- a/reactos/lib/rtl/acl.c +++ b/reactos/lib/rtl/acl.c @@ -889,8 +889,7 @@ RtlValidAcl(IN PACL Acl) } /* Check what kind of ACE this is */ - if ((Ace->AceType >= ACCESS_MIN_MS_ACE_TYPE) || - (Ace->AceType <= ACCESS_MAX_MS_V2_ACE_TYPE)) + if (Ace->AceType <= ACCESS_MAX_MS_V2_ACE_TYPE) { /* Validate the length of this ACE */ if (ROUND_DOWN(Ace->AceSize, sizeof(ULONG)) != Ace->AceSize) @@ -932,7 +931,7 @@ RtlValidAcl(IN PACL Acl) { DPRINT1("Unsupported ACE in ReactOS, assuming valid\n"); } - else if ((Ace->AceType >= ACCESS_MIN_MS_OBJECT_ACE_TYPE) || + else if ((Ace->AceType >= ACCESS_MIN_MS_OBJECT_ACE_TYPE) && (Ace->AceType <= ACCESS_MAX_MS_OBJECT_ACE_TYPE)) { DPRINT1("Unsupported ACE in ReactOS, assuming valid\n");