aboutsummaryrefslogtreecommitdiff
path: root/winsup
diff options
context:
space:
mode:
authorCorinna Vinschen <corinna@vinschen.de>2009-04-21 20:10:55 +0000
committerCorinna Vinschen <corinna@vinschen.de>2009-04-21 20:10:55 +0000
commit27378802eaab30d4e43c2bc34867d2aaf5c3cff6 (patch)
tree7984f3615496cf84e05146973fbab9c9a7de8554 /winsup
parentc28545227a20b20a115921636489e526c7722c76 (diff)
downloadnewlib-27378802eaab30d4e43c2bc34867d2aaf5c3cff6.zip
newlib-27378802eaab30d4e43c2bc34867d2aaf5c3cff6.tar.gz
newlib-27378802eaab30d4e43c2bc34867d2aaf5c3cff6.tar.bz2
* ctype.cc (__set_ctype): Copy exact part of the current active
character class array.
Diffstat (limited to 'winsup')
-rw-r--r--winsup/cygwin/ChangeLog5
-rw-r--r--winsup/cygwin/ctype.cc4
2 files changed, 7 insertions, 2 deletions
diff --git a/winsup/cygwin/ChangeLog b/winsup/cygwin/ChangeLog
index 47b3efd..c069b28 100644
--- a/winsup/cygwin/ChangeLog
+++ b/winsup/cygwin/ChangeLog
@@ -1,3 +1,8 @@
+2009-04-21 Corinna Vinschen <corinna@vinschen.de>
+
+ * ctype.cc (__set_ctype): Copy exact part of the current active
+ character class array.
+
2009-04-20 Corinna Vinschen <corinna@vinschen.de>
* flock.cc (lf_setlock): Handle border case which results in WFMO loop
diff --git a/winsup/cygwin/ctype.cc b/winsup/cygwin/ctype.cc
index e0d6e71..224db4c 100644
--- a/winsup/cygwin/ctype.cc
+++ b/winsup/cygwin/ctype.cc
@@ -34,7 +34,7 @@ __set_ctype (const char *charset)
if (CYGWIN_VERSION_CHECK_FOR_OLD_CTYPE)
{
memcpy (_ctype_b, __ctype_iso[idx], 128);
- memcpy (_ctype_b + 256, __ctype_iso[idx], 128);
+ memcpy (_ctype_b + 256, __ctype_iso[idx] + 256, 128);
}
__ctype_ptr__ = (char *) (__ctype_iso[idx] + 127);
return;
@@ -45,7 +45,7 @@ __set_ctype (const char *charset)
if (CYGWIN_VERSION_CHECK_FOR_OLD_CTYPE)
{
memcpy (_ctype_b, __ctype_cp[idx], 128);
- memcpy (_ctype_b + 256, __ctype_cp[idx], 128);
+ memcpy (_ctype_b + 256, __ctype_cp[idx] + 256, 128);
}
__ctype_ptr__ = (char *) (__ctype_cp[idx] + 127);
return;