ntdll: Cast-qual warning fix

Andrew Talbot Andrew.Talbot at talbotville.com
Tue Jul 24 17:46:44 CDT 2007


Changelog:
    ntdll: Cast-qual warning fix.

diff -urN a/dlls/ntdll/directory.c b/dlls/ntdll/directory.c
--- a/dlls/ntdll/directory.c	2007-06-29 14:16:57.000000000 +0100
+++ b/dlls/ntdll/directory.c	2007-07-24 23:40:54.000000000 +0100
@@ -1460,8 +1460,11 @@
 static inline WCHAR *mempbrkW( const WCHAR *ptr, const WCHAR *accept, size_t n )
 {
     const WCHAR *end;
-    for (end = ptr + n; ptr < end; ptr++) if (strchrW( accept, *ptr )) return (WCHAR *)ptr;
-    return NULL;
+    WCHAR *ret = NULL;
+
+    for (end = ptr + n; ptr < end && !((ret = strchrW( accept, *ptr ))); ++ptr)
+        ;
+    return ret;
 }
 
 /******************************************************************************



More information about the wine-patches mailing list