[RTL]
authorThomas Faber <thomas.faber@reactos.org>
Sun, 2 Oct 2016 08:34:30 +0000 (08:34 +0000)
committerThomas Faber <thomas.faber@reactos.org>
Sun, 2 Oct 2016 08:34:30 +0000 (08:34 +0000)
- Only check for MBCS lead bytes in RtlIsTextUnicode if specifically requested
CORE-12027 #resolve for real this time

svn path=/trunk/; revision=72887

reactos/sdk/lib/rtl/unicode.c

index a6185b9..99da382 100644 (file)
@@ -1367,7 +1367,7 @@ RtlIsTextUnicode(CONST VOID* buf, INT len, INT* pf)
             else
                 weight = 1;
 
             else
                 weight = 1;
 
-            if (flags & IS_TEXT_UNICODE_DBCS_LEADBYTE)
+            if (pf && (*pf & IS_TEXT_UNICODE_DBCS_LEADBYTE))
                 out_flags |= IS_TEXT_UNICODE_DBCS_LEADBYTE;
         }
     }
                 out_flags |= IS_TEXT_UNICODE_DBCS_LEADBYTE;
         }
     }