Download
Getting Started
Members
Projects
Community
Marketplace
Events
Planet Eclipse
Newsletter
Videos
Participate
Report a Bug
Forums
Mailing Lists
Wiki
IRC
How to Contribute
Working Groups
Automotive
Internet of Things
LocationTech
Long-Term Support
PolarSys
Science
OpenMDM
More
Community
Marketplace
Events
Planet Eclipse
Newsletter
Videos
Participate
Report a Bug
Forums
Mailing Lists
Wiki
IRC
How to Contribute
Working Groups
Automotive
Internet of Things
LocationTech
Long-Term Support
PolarSys
Science
OpenMDM
Toggle navigation
Bugzilla – Attachment 34054 Details for
Bug 126293
Non-8 bit characters are garbled in in-editor validation
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Requests
|
Help
|
Log In
[x]
|
Terms of Use
|
Copyright Agent
[patch]
Patch for org.eclipse.wst.xml.core and .ui which uses UTF-8
org.eclipse.wst.xml-validator-charset-bug.txt (text/plain), 2.40 KB, created by
Jesper Moller
on 2006-02-02 18:59:51 EST
(
hide
)
Description:
Patch for org.eclipse.wst.xml.core and .ui which uses UTF-8
Filename:
MIME Type:
Creator:
Jesper Moller
Created:
2006-02-02 18:59:51 EST
Size:
2.40 KB
patch
obsolete
>### Eclipse Workspace Patch 1.0 >#P org.eclipse.wst.xml.core >Index: src-validation/org/eclipse/wst/xml/core/internal/validation/XMLValidator.java >=================================================================== >RCS file: /cvsroot/webtools/wst/components/xml/plugins/org.eclipse.wst.xml.core/src-validation/org/eclipse/wst/xml/core/internal/validation/XMLValidator.java,v >retrieving revision 1.10 >diff -u -r1.10 XMLValidator.java >--- src-validation/org/eclipse/wst/xml/core/internal/validation/XMLValidator.java 10 Nov 2005 05:11:58 -0000 1.10 >+++ src-validation/org/eclipse/wst/xml/core/internal/validation/XMLValidator.java 2 Feb 2006 23:44:51 -0000 >@@ -152,7 +152,7 @@ > StringBuffer fileString = new StringBuffer(); > try > { >- InputStreamReader inputReader = new InputStreamReader(inputStream); >+ InputStreamReader inputReader = new InputStreamReader(inputStream, "UTF-8"); > BufferedReader reader = new BufferedReader(inputReader); > char[] chars = new char[1024]; > int numberRead = reader.read(chars); >#P org.eclipse.wst.xml.ui >Index: src/org/eclipse/wst/xml/ui/internal/validation/DelegatingSourceValidator.java >=================================================================== >RCS file: /cvsroot/webtools/wst/components/xml/plugins/org.eclipse.wst.xml.ui/src/org/eclipse/wst/xml/ui/internal/validation/DelegatingSourceValidator.java,v >retrieving revision 1.10 >diff -u -r1.10 DelegatingSourceValidator.java >--- src/org/eclipse/wst/xml/ui/internal/validation/DelegatingSourceValidator.java 10 Nov 2005 05:15:27 -0000 1.10 >+++ src/org/eclipse/wst/xml/ui/internal/validation/DelegatingSourceValidator.java 2 Feb 2006 23:44:53 -0000 >@@ -13,6 +13,7 @@ > > import java.io.ByteArrayInputStream; > import java.io.InputStream; >+import java.io.UnsupportedEncodingException; > import java.util.ArrayList; > import java.util.List; > >@@ -173,7 +174,13 @@ > > // store the text in a byte array; make a full copy to ease > // any threading problems >- byte[] byteArray = xmlModel.getStructuredDocument().get().getBytes(); >+ byte[] byteArray; >+ try { >+ byteArray = xmlModel.getStructuredDocument().get().getBytes("UTF-8"); >+ } catch (UnsupportedEncodingException e) { >+ // Not likely to happen >+ byteArray = xmlModel.getStructuredDocument().get().getBytes(); >+ } > > IValidator validator = getDelegateValidator(); > if (validator != null) {
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
Attachments on
bug 126293
:
34052
|
34053
| 34054