Author: tkreuzer
Date: Tue Aug 26 20:47:34 2008
New Revision: 35691
URL:
http://svn.reactos.org/svn/reactos?rev=35691&view=rev
Log:
Optimize and shorten StringCxxLength
Modified:
branches/ros-amd64-bringup/reactos/include/psdk/strsafe.h
Modified: branches/ros-amd64-bringup/reactos/include/psdk/strsafe.h
URL:
http://svn.reactos.org/svn/reactos/branches/ros-amd64-bringup/reactos/inclu…
==============================================================================
--- branches/ros-amd64-bringup/reactos/include/psdk/strsafe.h [iso-8859-1] (original)
+++ branches/ros-amd64-bringup/reactos/include/psdk/strsafe.h [iso-8859-1] Tue Aug 26
20:47:34 2008
@@ -286,11 +286,7 @@
return STRSAFE_E_INVALID_PARAMETER;
}
- while (*psz != 0 && cch != 0)
- {
- cch--;
- psz++;
- }
+ for (--psz; *(++psz) != 0 && --cch > 0;);
if (cch == 0)
{