Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/mono/mono.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorGonzalo Paniagua Javier <gonzalo.mono@gmail.com>2003-03-06 02:45:51 +0300
committerGonzalo Paniagua Javier <gonzalo.mono@gmail.com>2003-03-06 02:45:51 +0300
commitf3609d9a4f88c4999330c720e6211e39d9d25744 (patch)
tree8334953cc69d1a004dfcfd652edf60083be101ed
parent5ea869194c96a4e686eb3af81397dfcd88095ef6 (diff)
2003-03-05 Gonzalo Paniagua Javier <gonzalo@ximian.com>
* ASCIIEncoding.cs: fixed bug #38984. svn path=/trunk/mcs/; revision=12235
-rwxr-xr-xmcs/class/corlib/System.Text/ASCIIEncoding.cs5
-rwxr-xr-xmcs/class/corlib/System.Text/ChangeLog4
2 files changed, 8 insertions, 1 deletions
diff --git a/mcs/class/corlib/System.Text/ASCIIEncoding.cs b/mcs/class/corlib/System.Text/ASCIIEncoding.cs
index 449744f2a8f..4f07982e3c8 100755
--- a/mcs/class/corlib/System.Text/ASCIIEncoding.cs
+++ b/mcs/class/corlib/System.Text/ASCIIEncoding.cs
@@ -169,7 +169,10 @@ public class ASCIIEncoding : Encoding
}
int count = byteCount;
while (count-- > 0) {
- chars [charIndex++] = (char)(bytes [byteIndex++]);
+ char c = (char)(bytes [byteIndex++]);
+ if (c > 127)
+ c = '?';
+ chars [charIndex++] = c;
}
return byteCount;
}
diff --git a/mcs/class/corlib/System.Text/ChangeLog b/mcs/class/corlib/System.Text/ChangeLog
index eb0bc680a92..f555754acdd 100755
--- a/mcs/class/corlib/System.Text/ChangeLog
+++ b/mcs/class/corlib/System.Text/ChangeLog
@@ -1,3 +1,7 @@
+2003-03-05 Gonzalo Paniagua Javier <gonzalo@ximian.com>
+
+ * ASCIIEncoding.cs: fixed bug #38984.
+
2003-03-05 Aleksey Demakov <avd@openlinksw.com>
* ASCIIEncoding.cs: