hadoop-common-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Hitesh Shah (JIRA)" <j...@apache.org>
Subject [jira] [Commented] (HADOOP-9276) Allow BoundedByteArrayOutputStream to be resettable
Date Fri, 01 Feb 2013 22:48:13 GMT

    [ https://issues.apache.org/jira/browse/HADOOP-9276?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13569189#comment-13569189
] 

Hitesh Shah commented on HADOOP-9276:
-------------------------------------

Sorry - found one more issue. 

{code}
   public void reset() {
     this.limit = buffer.length;
-    this.count = 0;
+    this.currentPointer = startOffset;
{code}

limit here should be set to buffer.length - startOffset to prevent problems when startOffset
is non-zero. 
                
> Allow BoundedByteArrayOutputStream to be resettable
> ---------------------------------------------------
>
>                 Key: HADOOP-9276
>                 URL: https://issues.apache.org/jira/browse/HADOOP-9276
>             Project: Hadoop Common
>          Issue Type: Improvement
>            Reporter: Arun C Murthy
>            Assignee: Arun C Murthy
>            Priority: Minor
>         Attachments: HADOOP-9276.patch, HADOOP-9276.patch
>
>
> Allow BoundedByteArrayOutputStream's byte[] to be resettable.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira

Mime
View raw message