You are viewing a plain text version of this content. The canonical link for it is here.
Posted to common-dev@hadoop.apache.org by "Srikanth Kakani (JIRA)" <ji...@apache.org> on 2007/05/02 00:07:16 UTC
[jira] Created: (HADOOP-1311) Bug in BytesWritable.set(byte[]
newData, int offset, int length)
Bug in BytesWritable.set(byte[] newData, int offset, int length)
-----------------------------------------------------------------
Key: HADOOP-1311
URL: https://issues.apache.org/jira/browse/HADOOP-1311
Project: Hadoop
Issue Type: Bug
Components: io
Environment: N/A
Reporter: Srikanth Kakani
Current implementation:
public void set(byte[] newData, int offset, int length) {
setSize(0);
setSize(length);
System.arraycopy(newData, 0, bytes, 0, size);
}
Correct implementation:
public void set(byte[] newData, int offset, int length) {
setSize(0);
setSize(length);
System.arraycopy(newData, offset, bytes, 0, size);
}
please fix.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Commented: (HADOOP-1311) Bug in BytesWritable.set(byte[]
newData, int offset, int length)
Posted by "Hadoop QA (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/HADOOP-1311?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#action_12500222 ]
Hadoop QA commented on HADOOP-1311:
-----------------------------------
+1
http://issues.apache.org/jira/secure/attachment/12358569/bytesWritable.patch applied and successfully tested against trunk revision r542595.
Test results: http://lucene.zones.apache.org:8080/hudson/job/Hadoop-Patch/218/testReport/
Console output: http://lucene.zones.apache.org:8080/hudson/job/Hadoop-Patch/218/console
> Bug in BytesWritable.set(byte[] newData, int offset, int length)
> -----------------------------------------------------------------
>
> Key: HADOOP-1311
> URL: https://issues.apache.org/jira/browse/HADOOP-1311
> Project: Hadoop
> Issue Type: Bug
> Components: io
> Environment: N/A
> Reporter: Srikanth Kakani
> Attachments: bytesWritable.patch
>
>
> Current implementation:
> public void set(byte[] newData, int offset, int length) {
> setSize(0);
> setSize(length);
> System.arraycopy(newData, 0, bytes, 0, size);
> }
> Correct implementation:
> public void set(byte[] newData, int offset, int length) {
> setSize(0);
> setSize(length);
> System.arraycopy(newData, offset, bytes, 0, size);
> }
> please fix.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Assigned: (HADOOP-1311) Bug in BytesWritable.set(byte[]
newData, int offset, int length)
Posted by "dhruba borthakur (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/HADOOP-1311?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
dhruba borthakur reassigned HADOOP-1311:
----------------------------------------
Assignee: dhruba borthakur
> Bug in BytesWritable.set(byte[] newData, int offset, int length)
> -----------------------------------------------------------------
>
> Key: HADOOP-1311
> URL: https://issues.apache.org/jira/browse/HADOOP-1311
> Project: Hadoop
> Issue Type: Bug
> Components: io
> Environment: N/A
> Reporter: Srikanth Kakani
> Assignee: dhruba borthakur
> Attachments: bytesWritable.patch
>
>
> Current implementation:
> public void set(byte[] newData, int offset, int length) {
> setSize(0);
> setSize(length);
> System.arraycopy(newData, 0, bytes, 0, size);
> }
> Correct implementation:
> public void set(byte[] newData, int offset, int length) {
> setSize(0);
> setSize(length);
> System.arraycopy(newData, offset, bytes, 0, size);
> }
> please fix.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Commented: (HADOOP-1311) Bug in BytesWritable.set(byte[]
newData, int offset, int length)
Posted by "Hadoop QA (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/HADOOP-1311?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#action_12500537 ]
Hadoop QA commented on HADOOP-1311:
-----------------------------------
+1
http://issues.apache.org/jira/secure/attachment/12358569/bytesWritable.patch applied and successfully tested against trunk revision r543222.
Test results: http://lucene.zones.apache.org:8080/hudson/job/Hadoop-Patch/225/testReport/
Console output: http://lucene.zones.apache.org:8080/hudson/job/Hadoop-Patch/225/console
> Bug in BytesWritable.set(byte[] newData, int offset, int length)
> -----------------------------------------------------------------
>
> Key: HADOOP-1311
> URL: https://issues.apache.org/jira/browse/HADOOP-1311
> Project: Hadoop
> Issue Type: Bug
> Components: io
> Environment: N/A
> Reporter: Srikanth Kakani
> Assignee: dhruba borthakur
> Attachments: bytesWritable.patch
>
>
> Current implementation:
> public void set(byte[] newData, int offset, int length) {
> setSize(0);
> setSize(length);
> System.arraycopy(newData, 0, bytes, 0, size);
> }
> Correct implementation:
> public void set(byte[] newData, int offset, int length) {
> setSize(0);
> setSize(length);
> System.arraycopy(newData, offset, bytes, 0, size);
> }
> please fix.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Commented: (HADOOP-1311) Bug in BytesWritable.set(byte[]
newData, int offset, int length)
Posted by "Hadoop QA (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/HADOOP-1311?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#action_12503919 ]
Hadoop QA commented on HADOOP-1311:
-----------------------------------
Integrated in Hadoop-Nightly #119 (See [http://lucene.zones.apache.org:8080/hudson/job/Hadoop-Nightly/119/])
> Bug in BytesWritable.set(byte[] newData, int offset, int length)
> -----------------------------------------------------------------
>
> Key: HADOOP-1311
> URL: https://issues.apache.org/jira/browse/HADOOP-1311
> Project: Hadoop
> Issue Type: Bug
> Components: io
> Environment: N/A
> Reporter: Srikanth Kakani
> Assignee: dhruba borthakur
> Fix For: 0.14.0
>
> Attachments: bytesWritable.patch
>
>
> Current implementation:
> public void set(byte[] newData, int offset, int length) {
> setSize(0);
> setSize(length);
> System.arraycopy(newData, 0, bytes, 0, size);
> }
> Correct implementation:
> public void set(byte[] newData, int offset, int length) {
> setSize(0);
> setSize(length);
> System.arraycopy(newData, offset, bytes, 0, size);
> }
> please fix.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Commented: (HADOOP-1311) Bug in BytesWritable.set(byte[]
newData, int offset, int length)
Posted by "dhruba borthakur (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/HADOOP-1311?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#action_12500515 ]
dhruba borthakur commented on HADOOP-1311:
------------------------------------------
But just before the call to arraycopy, we invoke setSize(length). This sets size = length. Thus, size and length are the same when the arraycopy is invoked.
> Bug in BytesWritable.set(byte[] newData, int offset, int length)
> -----------------------------------------------------------------
>
> Key: HADOOP-1311
> URL: https://issues.apache.org/jira/browse/HADOOP-1311
> Project: Hadoop
> Issue Type: Bug
> Components: io
> Environment: N/A
> Reporter: Srikanth Kakani
> Attachments: bytesWritable.patch
>
>
> Current implementation:
> public void set(byte[] newData, int offset, int length) {
> setSize(0);
> setSize(length);
> System.arraycopy(newData, 0, bytes, 0, size);
> }
> Correct implementation:
> public void set(byte[] newData, int offset, int length) {
> setSize(0);
> setSize(length);
> System.arraycopy(newData, offset, bytes, 0, size);
> }
> please fix.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Updated: (HADOOP-1311) Bug in BytesWritable.set(byte[]
newData, int offset, int length)
Posted by "dhruba borthakur (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/HADOOP-1311?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
dhruba borthakur updated HADOOP-1311:
-------------------------------------
Status: Patch Available (was: Open)
Please review and commit if appropriate.
> Bug in BytesWritable.set(byte[] newData, int offset, int length)
> -----------------------------------------------------------------
>
> Key: HADOOP-1311
> URL: https://issues.apache.org/jira/browse/HADOOP-1311
> Project: Hadoop
> Issue Type: Bug
> Components: io
> Environment: N/A
> Reporter: Srikanth Kakani
> Attachments: bytesWritable.patch
>
>
> Current implementation:
> public void set(byte[] newData, int offset, int length) {
> setSize(0);
> setSize(length);
> System.arraycopy(newData, 0, bytes, 0, size);
> }
> Correct implementation:
> public void set(byte[] newData, int offset, int length) {
> setSize(0);
> setSize(length);
> System.arraycopy(newData, offset, bytes, 0, size);
> }
> please fix.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Updated: (HADOOP-1311) Bug in BytesWritable.set(byte[]
newData, int offset, int length)
Posted by "dhruba borthakur (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/HADOOP-1311?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
dhruba borthakur updated HADOOP-1311:
-------------------------------------
Attachment: bytesWritable.patch
> Bug in BytesWritable.set(byte[] newData, int offset, int length)
> -----------------------------------------------------------------
>
> Key: HADOOP-1311
> URL: https://issues.apache.org/jira/browse/HADOOP-1311
> Project: Hadoop
> Issue Type: Bug
> Components: io
> Environment: N/A
> Reporter: Srikanth Kakani
> Attachments: bytesWritable.patch
>
>
> Current implementation:
> public void set(byte[] newData, int offset, int length) {
> setSize(0);
> setSize(length);
> System.arraycopy(newData, 0, bytes, 0, size);
> }
> Correct implementation:
> public void set(byte[] newData, int offset, int length) {
> setSize(0);
> setSize(length);
> System.arraycopy(newData, offset, bytes, 0, size);
> }
> please fix.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Updated: (HADOOP-1311) Bug in BytesWritable.set(byte[]
newData, int offset, int length)
Posted by "Doug Cutting (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/HADOOP-1311?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Doug Cutting updated HADOOP-1311:
---------------------------------
Status: Open (was: Patch Available)
The final parameter to arraycopy should be 'length', not 'size', right?
> Bug in BytesWritable.set(byte[] newData, int offset, int length)
> -----------------------------------------------------------------
>
> Key: HADOOP-1311
> URL: https://issues.apache.org/jira/browse/HADOOP-1311
> Project: Hadoop
> Issue Type: Bug
> Components: io
> Environment: N/A
> Reporter: Srikanth Kakani
> Attachments: bytesWritable.patch
>
>
> Current implementation:
> public void set(byte[] newData, int offset, int length) {
> setSize(0);
> setSize(length);
> System.arraycopy(newData, 0, bytes, 0, size);
> }
> Correct implementation:
> public void set(byte[] newData, int offset, int length) {
> setSize(0);
> setSize(length);
> System.arraycopy(newData, offset, bytes, 0, size);
> }
> please fix.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Commented: (HADOOP-1311) Bug in BytesWritable.set(byte[]
newData, int offset, int length)
Posted by "Srikanth Kakani (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/HADOOP-1311?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#action_12500484 ]
Srikanth Kakani commented on HADOOP-1311:
-----------------------------------------
Yes. It should be length.
Thanks,
Srikanth
> Bug in BytesWritable.set(byte[] newData, int offset, int length)
> -----------------------------------------------------------------
>
> Key: HADOOP-1311
> URL: https://issues.apache.org/jira/browse/HADOOP-1311
> Project: Hadoop
> Issue Type: Bug
> Components: io
> Environment: N/A
> Reporter: Srikanth Kakani
> Attachments: bytesWritable.patch
>
>
> Current implementation:
> public void set(byte[] newData, int offset, int length) {
> setSize(0);
> setSize(length);
> System.arraycopy(newData, 0, bytes, 0, size);
> }
> Correct implementation:
> public void set(byte[] newData, int offset, int length) {
> setSize(0);
> setSize(length);
> System.arraycopy(newData, offset, bytes, 0, size);
> }
> please fix.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Updated: (HADOOP-1311) Bug in BytesWritable.set(byte[]
newData, int offset, int length)
Posted by "dhruba borthakur (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/HADOOP-1311?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
dhruba borthakur updated HADOOP-1311:
-------------------------------------
Status: Patch Available (was: Open)
Please review again.
> Bug in BytesWritable.set(byte[] newData, int offset, int length)
> -----------------------------------------------------------------
>
> Key: HADOOP-1311
> URL: https://issues.apache.org/jira/browse/HADOOP-1311
> Project: Hadoop
> Issue Type: Bug
> Components: io
> Environment: N/A
> Reporter: Srikanth Kakani
> Attachments: bytesWritable.patch
>
>
> Current implementation:
> public void set(byte[] newData, int offset, int length) {
> setSize(0);
> setSize(length);
> System.arraycopy(newData, 0, bytes, 0, size);
> }
> Correct implementation:
> public void set(byte[] newData, int offset, int length) {
> setSize(0);
> setSize(length);
> System.arraycopy(newData, offset, bytes, 0, size);
> }
> please fix.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Updated: (HADOOP-1311) Bug in BytesWritable.set(byte[]
newData, int offset, int length)
Posted by "Doug Cutting (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/HADOOP-1311?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Doug Cutting updated HADOOP-1311:
---------------------------------
Resolution: Fixed
Fix Version/s: 0.14.0
Status: Resolved (was: Patch Available)
I just committed this. Thanks, Dhruba!
> Bug in BytesWritable.set(byte[] newData, int offset, int length)
> -----------------------------------------------------------------
>
> Key: HADOOP-1311
> URL: https://issues.apache.org/jira/browse/HADOOP-1311
> Project: Hadoop
> Issue Type: Bug
> Components: io
> Environment: N/A
> Reporter: Srikanth Kakani
> Assignee: dhruba borthakur
> Fix For: 0.14.0
>
> Attachments: bytesWritable.patch
>
>
> Current implementation:
> public void set(byte[] newData, int offset, int length) {
> setSize(0);
> setSize(length);
> System.arraycopy(newData, 0, bytes, 0, size);
> }
> Correct implementation:
> public void set(byte[] newData, int offset, int length) {
> setSize(0);
> setSize(length);
> System.arraycopy(newData, offset, bytes, 0, size);
> }
> please fix.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.