Fix implementation of wcsnlen and strnlen.
Modified: trunk/reactos/lib/kernel32/mem/isbad.c
_____
Modified: trunk/reactos/lib/kernel32/mem/isbad.c
--- trunk/reactos/lib/kernel32/mem/isbad.c 2005-08-21 15:51:23 UTC
(rev 17463)
+++ trunk/reactos/lib/kernel32/mem/isbad.c 2005-08-21 15:51:57 UTC
(rev 17464)
@@ -21,7 +21,7 @@
)
{
UINT i = 0;
- while( lpsz[i] && i < ucchMax ) i++;
+ while( i < ucchMax && lpsz[i] ) i++;
return i;
}
@@ -37,7 +37,7 @@
)
{
UINT i = 0;
- while( lpsz[i] && i < uiMax ) i++;
+ while( i < uiMax && lpsz[i] ) i++;
return i;
}
Show replies by date