Author: akhaldi
Date: Sat Jun 3 17:28:54 2017
New Revision: 74772
URL:
http://svn.reactos.org/svn/reactos?rev=74772&view=rev
Log:
[XCOPY] Sync with Wine Staging 2.9. CORE-13362
373604f xcopy: Avoid using isdigit() for WCHARs.
Modified:
trunk/reactos/base/applications/cmdutils/xcopy/xcopy.c
trunk/reactos/media/doc/README.WINE
Modified: trunk/reactos/base/applications/cmdutils/xcopy/xcopy.c
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/base/applications/cmdutils…
==============================================================================
--- trunk/reactos/base/applications/cmdutils/xcopy/xcopy.c [iso-8859-1] (original)
+++ trunk/reactos/base/applications/cmdutils/xcopy/xcopy.c [iso-8859-1] Sat Jun 3
17:28:54 2017
@@ -648,7 +648,7 @@
/* =========================================================================
XCOPY_ParseCommandLine - Parses the command line
========================================================================= */
-static BOOL is_whitespace(WCHAR c)
+static inline BOOL is_whitespace(WCHAR c)
{
return c == ' ' || c == '\t';
}
@@ -657,6 +657,11 @@
{
for (; *p && is_whitespace(*p); p++);
return p;
+}
+
+static inline BOOL is_digit(WCHAR c)
+{
+ return c >= '0' && c <= '9';
}
/* Windows XCOPY uses a simplified command line parsing algorithm
@@ -775,7 +780,7 @@
break;
/* D can be /D or /D: */
- case 'D': if (word[2]==':' && isdigit(word[3])) {
+ case 'D': if (word[2]==':' && is_digit(word[3])) {
SYSTEMTIME st;
WCHAR *pos = &word[3];
BOOL isError = FALSE;
@@ -786,18 +791,18 @@
* It is hardcoded to month-day-year.
*/
st.wMonth = _wtol(pos);
- while (*pos && isdigit(*pos)) pos++;
+ while (*pos && is_digit(*pos)) pos++;
if (*pos++ != '-') isError = TRUE;
if (!isError) {
st.wDay = _wtol(pos);
- while (*pos && isdigit(*pos)) pos++;
+ while (*pos && is_digit(*pos)) pos++;
if (*pos++ != '-') isError = TRUE;
}
if (!isError) {
st.wYear = _wtol(pos);
- while (*pos && isdigit(*pos)) pos++;
+ while (*pos && is_digit(*pos)) pos++;
if (st.wYear < 100) st.wYear+=2000;
}
Modified: trunk/reactos/media/doc/README.WINE
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/media/doc/README.WINE?rev=…
==============================================================================
--- trunk/reactos/media/doc/README.WINE [iso-8859-1] (original)
+++ trunk/reactos/media/doc/README.WINE [iso-8859-1] Sat Jun 3 17:28:54 2017
@@ -232,7 +232,7 @@
reactos/base/applications/cmdutils/taskkill # Synced to WineStaging-1.9.11
reactos/base/applications/cmdutils/wmic # Synced to WineStaging-2.2
reactos/base/applications/cmdutils/wscript # Synced to WineStaging-1.9.16
-reactos/base/applications/cmdutils/xcopy # Synced to WineStaging-1.9.11
+reactos/base/applications/cmdutils/xcopy # Synced to WineStaging-2.9
reactos/base/applications/games/winmine # Synced to WineStaging-1.9.16 with our own
resources.
reactos/base/applications/extrac32 # Synced to WineStaging-1.9.11
reactos/base/applications/iexplore # Synced to WineStaging-1.9.11