You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commons-dev@ws.apache.org by "Davanum Srinivas (JIRA)" <ji...@apache.org> on 2007/03/16 02:13:10 UTC

[jira] Commented: (WSCOMMONS-169) Boundary calculation and other byte/String processing should honor the char encoding of the message

    [ https://issues.apache.org/jira/browse/WSCOMMONS-169?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#action_12481407 ] 

Davanum Srinivas commented on WSCOMMONS-169:
--------------------------------------------

Rich, 

Can you please do this as part of the attachment work you are already working on?

thanks,
dims

> Boundary calculation and other byte/String processing should honor the char encoding of the message
> ---------------------------------------------------------------------------------------------------
>
>                 Key: WSCOMMONS-169
>                 URL: https://issues.apache.org/jira/browse/WSCOMMONS-169
>             Project: WS-Commons
>          Issue Type: Bug
>          Components: AXIOM
>            Reporter: Rich Scheuerle
>         Assigned To: Rich Scheuerle
>            Priority: Minor
>
> The boundary byte calulation should honor the character encoding of the message.
> Here are two examples:
> In MIMEOutputUtils:
>  public static void writeMimeBoundary(OutputStream outStream,
>                                          String boundary) throws IOException {
>         outStream.write(new byte[]{45, 45});
>         outStream.write(boundary.getBytes("UTF-8"));  <---- Should use character encoding of the message
>     } 
> In Attachments:
>     // Boundary always have the prefix "--".
>         this.boundary = ("--" + contentType.getParameter("boundary"))
>                 .getBytes("UTF-8"); <---- Should use character encoding of the message
> Changing the calculations to use the encoding of the message may cause breakage in the lower level ByteDelimittedInputStream code and related classes due to (A) hard-coded character usage and (B) assumptions that characters are represented as single bytes.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


---------------------------------------------------------------------
To unsubscribe, e-mail: commons-dev-unsubscribe@ws.apache.org
For additional commands, e-mail: commons-dev-help@ws.apache.org