You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@harmony.apache.org by "Andrew Zhang (JIRA)" <ji...@apache.org> on 2007/01/02 15:28:31 UTC
[jira] Created: (HARMONY-2937) [classlib][sql]
SerialBlob.truncate(long length) should not change buffer length is the
length parameter is invalid.
[classlib][sql] SerialBlob.truncate(long length) should not change buffer length is the length parameter is invalid.
--------------------------------------------------------------------------------------------------------------------
Key: HARMONY-2937
URL: http://issues.apache.org/jira/browse/HARMONY-2937
Project: Harmony
Issue Type: Bug
Components: Non-bug differences from RI
Reporter: Andrew Zhang
Hi, as discussed in dev mailing list, SerialBlob.truncate(long length) should not change buffer length is the length parameter is invalid. Following test shows the case:
public void testTruncateJ() throws Exception {
byte[] buf = { 1, 2, 3, 4, 5, 6, 7, 8 };
SerialBlob serialBlob1 = new SerialBlob(buf);
try {
serialBlob1.truncate(-1);
} catch (SerialException e) {
System.out.println(e.getMessage());
}
System.out.println(serialBlob1.length());
}
RI output is as follow:
Invalid arguments: position cannot be less that 1
-1
The buffer length is changed to -1 while SerialException is thrown too. Keeping the length as the old value makes more sense. Harmony won't follow RI's behaviour for this case, and keep it as a non-different-bug from RI.
Best regards,
Andrew
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira
[jira] Assigned: (HARMONY-2937) [classlib][sql]
SerialBlob.truncate(long length) should not change buffer length is the
length parameter is invalid.
Posted by "Tim Ellison (JIRA)" <ji...@apache.org>.
[ http://issues.apache.org/jira/browse/HARMONY-2937?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Tim Ellison reassigned HARMONY-2937:
------------------------------------
Assignee: Tim Ellison
> [classlib][sql] SerialBlob.truncate(long length) should not change buffer length is the length parameter is invalid.
> --------------------------------------------------------------------------------------------------------------------
>
> Key: HARMONY-2937
> URL: http://issues.apache.org/jira/browse/HARMONY-2937
> Project: Harmony
> Issue Type: Bug
> Components: Non-bug differences from RI
> Reporter: Andrew Zhang
> Assigned To: Tim Ellison
> Attachments: patch.diff
>
>
> Hi, as discussed in dev mailing list, SerialBlob.truncate(long length) should not change buffer length is the length parameter is invalid. Following test shows the case:
> public void testTruncateJ() throws Exception {
> byte[] buf = { 1, 2, 3, 4, 5, 6, 7, 8 };
> SerialBlob serialBlob1 = new SerialBlob(buf);
> try {
> serialBlob1.truncate(-1);
> } catch (SerialException e) {
> System.out.println(e.getMessage());
> }
> System.out.println(serialBlob1.length());
> }
> RI output is as follow:
> Invalid arguments: position cannot be less that 1
> -1
> The buffer length is changed to -1 while SerialException is thrown too. Keeping the length as the old value makes more sense. Harmony won't follow RI's behaviour for this case, and keep it as a non-different-bug from RI.
> Best regards,
> Andrew
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira
[jira] Resolved: (HARMONY-2937) [classlib][sql]
SerialBlob.truncate(long length) should not change buffer length is the
length parameter is invalid.
Posted by "Tim Ellison (JIRA)" <ji...@apache.org>.
[ http://issues.apache.org/jira/browse/HARMONY-2937?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Tim Ellison resolved HARMONY-2937.
----------------------------------
Resolution: Won't Fix
Thanks Andrew,
Regression test applied to SQL module at repo revision r491814.
Please check that it was applied as you expected. I'll resolve this as won't fix.
> [classlib][sql] SerialBlob.truncate(long length) should not change buffer length is the length parameter is invalid.
> --------------------------------------------------------------------------------------------------------------------
>
> Key: HARMONY-2937
> URL: http://issues.apache.org/jira/browse/HARMONY-2937
> Project: Harmony
> Issue Type: Bug
> Components: Non-bug differences from RI
> Reporter: Andrew Zhang
> Assigned To: Tim Ellison
> Attachments: patch.diff
>
>
> Hi, as discussed in dev mailing list, SerialBlob.truncate(long length) should not change buffer length is the length parameter is invalid. Following test shows the case:
> public void testTruncateJ() throws Exception {
> byte[] buf = { 1, 2, 3, 4, 5, 6, 7, 8 };
> SerialBlob serialBlob1 = new SerialBlob(buf);
> try {
> serialBlob1.truncate(-1);
> } catch (SerialException e) {
> System.out.println(e.getMessage());
> }
> System.out.println(serialBlob1.length());
> }
> RI output is as follow:
> Invalid arguments: position cannot be less that 1
> -1
> The buffer length is changed to -1 while SerialException is thrown too. Keeping the length as the old value makes more sense. Harmony won't follow RI's behaviour for this case, and keep it as a non-different-bug from RI.
> Best regards,
> Andrew
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira
[jira] Closed: (HARMONY-2937) [classlib][sql]
SerialBlob.truncate(long length) should not change buffer length is the
length parameter is invalid.
Posted by "Tim Ellison (JIRA)" <ji...@apache.org>.
[ http://issues.apache.org/jira/browse/HARMONY-2937?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Tim Ellison closed HARMONY-2937.
--------------------------------
Verified by Andrew.
> [classlib][sql] SerialBlob.truncate(long length) should not change buffer length is the length parameter is invalid.
> --------------------------------------------------------------------------------------------------------------------
>
> Key: HARMONY-2937
> URL: http://issues.apache.org/jira/browse/HARMONY-2937
> Project: Harmony
> Issue Type: Bug
> Components: Non-bug differences from RI
> Reporter: Andrew Zhang
> Assigned To: Tim Ellison
> Attachments: patch.diff
>
>
> Hi, as discussed in dev mailing list, SerialBlob.truncate(long length) should not change buffer length is the length parameter is invalid. Following test shows the case:
> public void testTruncateJ() throws Exception {
> byte[] buf = { 1, 2, 3, 4, 5, 6, 7, 8 };
> SerialBlob serialBlob1 = new SerialBlob(buf);
> try {
> serialBlob1.truncate(-1);
> } catch (SerialException e) {
> System.out.println(e.getMessage());
> }
> System.out.println(serialBlob1.length());
> }
> RI output is as follow:
> Invalid arguments: position cannot be less that 1
> -1
> The buffer length is changed to -1 while SerialException is thrown too. Keeping the length as the old value makes more sense. Harmony won't follow RI's behaviour for this case, and keep it as a non-different-bug from RI.
> Best regards,
> Andrew
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira
[jira] Commented: (HARMONY-2937) [classlib][sql]
SerialBlob.truncate(long length) should not change buffer length is the
length parameter is invalid.
Posted by "Andrew Zhang (JIRA)" <ji...@apache.org>.
[ http://issues.apache.org/jira/browse/HARMONY-2937?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#action_12461754 ]
Andrew Zhang commented on HARMONY-2937:
---------------------------------------
Thanks Tim,
The fix looks good.
Best regards,
Andrew
> [classlib][sql] SerialBlob.truncate(long length) should not change buffer length is the length parameter is invalid.
> --------------------------------------------------------------------------------------------------------------------
>
> Key: HARMONY-2937
> URL: http://issues.apache.org/jira/browse/HARMONY-2937
> Project: Harmony
> Issue Type: Bug
> Components: Non-bug differences from RI
> Reporter: Andrew Zhang
> Assigned To: Tim Ellison
> Attachments: patch.diff
>
>
> Hi, as discussed in dev mailing list, SerialBlob.truncate(long length) should not change buffer length is the length parameter is invalid. Following test shows the case:
> public void testTruncateJ() throws Exception {
> byte[] buf = { 1, 2, 3, 4, 5, 6, 7, 8 };
> SerialBlob serialBlob1 = new SerialBlob(buf);
> try {
> serialBlob1.truncate(-1);
> } catch (SerialException e) {
> System.out.println(e.getMessage());
> }
> System.out.println(serialBlob1.length());
> }
> RI output is as follow:
> Invalid arguments: position cannot be less that 1
> -1
> The buffer length is changed to -1 while SerialException is thrown too. Keeping the length as the old value makes more sense. Harmony won't follow RI's behaviour for this case, and keep it as a non-different-bug from RI.
> Best regards,
> Andrew
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira
[jira] Commented: (HARMONY-2937) [classlib][sql]
SerialBlob.truncate(long length) should not change buffer length is the
length parameter is invalid.
Posted by "Andrew Zhang (JIRA)" <ji...@apache.org>.
[ http://issues.apache.org/jira/browse/HARMONY-2937?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#action_12461742 ]
Andrew Zhang commented on HARMONY-2937:
---------------------------------------
Hi,
Would you please apply my patch? Thanks!
Best regards,
Andrew
> [classlib][sql] SerialBlob.truncate(long length) should not change buffer length is the length parameter is invalid.
> --------------------------------------------------------------------------------------------------------------------
>
> Key: HARMONY-2937
> URL: http://issues.apache.org/jira/browse/HARMONY-2937
> Project: Harmony
> Issue Type: Bug
> Components: Non-bug differences from RI
> Reporter: Andrew Zhang
> Attachments: patch.diff
>
>
> Hi, as discussed in dev mailing list, SerialBlob.truncate(long length) should not change buffer length is the length parameter is invalid. Following test shows the case:
> public void testTruncateJ() throws Exception {
> byte[] buf = { 1, 2, 3, 4, 5, 6, 7, 8 };
> SerialBlob serialBlob1 = new SerialBlob(buf);
> try {
> serialBlob1.truncate(-1);
> } catch (SerialException e) {
> System.out.println(e.getMessage());
> }
> System.out.println(serialBlob1.length());
> }
> RI output is as follow:
> Invalid arguments: position cannot be less that 1
> -1
> The buffer length is changed to -1 while SerialException is thrown too. Keeping the length as the old value makes more sense. Harmony won't follow RI's behaviour for this case, and keep it as a non-different-bug from RI.
> Best regards,
> Andrew
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira
[jira] Updated: (HARMONY-2937) [classlib][sql]
SerialBlob.truncate(long length) should not change buffer length is the
length parameter is invalid.
Posted by "Andrew Zhang (JIRA)" <ji...@apache.org>.
[ http://issues.apache.org/jira/browse/HARMONY-2937?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Andrew Zhang updated HARMONY-2937:
----------------------------------
Attachment: patch.diff
> [classlib][sql] SerialBlob.truncate(long length) should not change buffer length is the length parameter is invalid.
> --------------------------------------------------------------------------------------------------------------------
>
> Key: HARMONY-2937
> URL: http://issues.apache.org/jira/browse/HARMONY-2937
> Project: Harmony
> Issue Type: Bug
> Components: Non-bug differences from RI
> Reporter: Andrew Zhang
> Attachments: patch.diff
>
>
> Hi, as discussed in dev mailing list, SerialBlob.truncate(long length) should not change buffer length is the length parameter is invalid. Following test shows the case:
> public void testTruncateJ() throws Exception {
> byte[] buf = { 1, 2, 3, 4, 5, 6, 7, 8 };
> SerialBlob serialBlob1 = new SerialBlob(buf);
> try {
> serialBlob1.truncate(-1);
> } catch (SerialException e) {
> System.out.println(e.getMessage());
> }
> System.out.println(serialBlob1.length());
> }
> RI output is as follow:
> Invalid arguments: position cannot be less that 1
> -1
> The buffer length is changed to -1 while SerialException is thrown too. Keeping the length as the old value makes more sense. Harmony won't follow RI's behaviour for this case, and keep it as a non-different-bug from RI.
> Best regards,
> Andrew
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira