You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@harmony.apache.org by "Oleg Khaschansky (JIRA)" <ji...@apache.org> on 2006/12/08 14:58:22 UTC
[jira] Created: (HARMONY-2547) [classlib][awt] PointerPointer's
methods set/get, set/getAddress don't use pointer size.
[classlib][awt] PointerPointer's methods set/get, set/getAddress don't use pointer size.
----------------------------------------------------------------------------------------
Key: HARMONY-2547
URL: http://issues.apache.org/jira/browse/HARMONY-2547
Project: Harmony
Issue Type: Bug
Components: Classlib
Reporter: Oleg Khaschansky
The following methods of org.apache.harmony.awt.nativebridge.PointerPointer
don't multiply index to elemnt size PP_SIZE_FACTOR: set(int, VoidPointer),
get(int), setAddress(int, long), getAddress(int).
Here's a small testcase:
import org.apache.harmony.awt.nativebridge.NativeBridge;
import org.apache.harmony.awt.nativebridge.PointerPointer;
public class PointerPointerTest {
public static void main(String[] args) {
PointerPointer p = NativeBridge.getInstance().createPointerPointer(2, false);
p.setAddress(0, 0xFFFFFFFF);
System.out.println("*(p+1) = " + Long.toHexString(p.getAddress(1)) + " should be 0");
}
}
--
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-2547) [classlib][awt] PointerPointer's
methods set/get, set/getAddress don't use pointer size.
Posted by "Alexei Zakharov (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/HARMONY-2547?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Alexei Zakharov updated HARMONY-2547:
-------------------------------------
Patch Info: [Patch Available]
> [classlib][awt] PointerPointer's methods set/get, set/getAddress don't use pointer size.
> ----------------------------------------------------------------------------------------
>
> Key: HARMONY-2547
> URL: https://issues.apache.org/jira/browse/HARMONY-2547
> Project: Harmony
> Issue Type: Bug
> Components: Classlib
> Reporter: Oleg Khaschansky
> Attachments: harmony-2547-test.patch, harmony-2547.patch
>
>
> The following methods of org.apache.harmony.awt.nativebridge.PointerPointer
> don't multiply index to elemnt size PP_SIZE_FACTOR: set(int, VoidPointer),
> get(int), setAddress(int, long), getAddress(int).
> Here's a small testcase:
> import org.apache.harmony.awt.nativebridge.NativeBridge;
> import org.apache.harmony.awt.nativebridge.PointerPointer;
> public class PointerPointerTest {
> public static void main(String[] args) {
> PointerPointer p = NativeBridge.getInstance().createPointerPointer(2, false);
> p.setAddress(0, 0xFFFFFFFF);
> System.out.println("*(p+1) = " + Long.toHexString(p.getAddress(1)) + " should be 0");
> }
> }
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Resolved: (HARMONY-2547) [classlib][awt] PointerPointer's
methods set/get, set/getAddress don't use pointer size.
Posted by "Alexei Zakharov (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/HARMONY-2547?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Alexei Zakharov resolved HARMONY-2547.
--------------------------------------
Resolution: Fixed
Assignee: Alexei Zakharov
Thanks Oleg. The patch for PointerPointer class as well as the unit test was committed at the revision 501086. Please verify.
NOTE: I've changed the package name of the test.
> [classlib][awt] PointerPointer's methods set/get, set/getAddress don't use pointer size.
> ----------------------------------------------------------------------------------------
>
> Key: HARMONY-2547
> URL: https://issues.apache.org/jira/browse/HARMONY-2547
> Project: Harmony
> Issue Type: Bug
> Components: Classlib
> Reporter: Oleg Khaschansky
> Assigned To: Alexei Zakharov
> Attachments: harmony-2547-test.patch, harmony-2547.patch
>
>
> The following methods of org.apache.harmony.awt.nativebridge.PointerPointer
> don't multiply index to elemnt size PP_SIZE_FACTOR: set(int, VoidPointer),
> get(int), setAddress(int, long), getAddress(int).
> Here's a small testcase:
> import org.apache.harmony.awt.nativebridge.NativeBridge;
> import org.apache.harmony.awt.nativebridge.PointerPointer;
> public class PointerPointerTest {
> public static void main(String[] args) {
> PointerPointer p = NativeBridge.getInstance().createPointerPointer(2, false);
> p.setAddress(0, 0xFFFFFFFF);
> System.out.println("*(p+1) = " + Long.toHexString(p.getAddress(1)) + " should be 0");
> }
> }
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Updated: (HARMONY-2547) [classlib][awt] PointerPointer's
methods set/get, set/getAddress don't use pointer size.
Posted by "Oleg Khaschansky (JIRA)" <ji...@apache.org>.
[ http://issues.apache.org/jira/browse/HARMONY-2547?page=all ]
Oleg Khaschansky updated HARMONY-2547:
--------------------------------------
Attachment: harmony-2547-test.patch
Unit tests. Contains a new file: src/test/api/java/org/apache/harmony/tests/java/awt/AWTPointerPointerTest.java
> [classlib][awt] PointerPointer's methods set/get, set/getAddress don't use pointer size.
> ----------------------------------------------------------------------------------------
>
> Key: HARMONY-2547
> URL: http://issues.apache.org/jira/browse/HARMONY-2547
> Project: Harmony
> Issue Type: Bug
> Components: Classlib
> Reporter: Oleg Khaschansky
> Attachments: harmony-2547-test.patch, harmony-2547.patch
>
>
> The following methods of org.apache.harmony.awt.nativebridge.PointerPointer
> don't multiply index to elemnt size PP_SIZE_FACTOR: set(int, VoidPointer),
> get(int), setAddress(int, long), getAddress(int).
> Here's a small testcase:
> import org.apache.harmony.awt.nativebridge.NativeBridge;
> import org.apache.harmony.awt.nativebridge.PointerPointer;
> public class PointerPointerTest {
> public static void main(String[] args) {
> PointerPointer p = NativeBridge.getInstance().createPointerPointer(2, false);
> p.setAddress(0, 0xFFFFFFFF);
> System.out.println("*(p+1) = " + Long.toHexString(p.getAddress(1)) + " should be 0");
> }
> }
--
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-2547) [classlib][awt] PointerPointer's
methods set/get, set/getAddress don't use pointer size.
Posted by "Stepan Mishura (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/HARMONY-2547?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#action_12468522 ]
Stepan Mishura commented on HARMONY-2547:
-----------------------------------------
Hi Alexei and Oleg,
The test org.apache.harmony.awt.tests.nativebridge.PointerPointerTest fails on Linux x86_64 with:
1) test_set
Wrong number of elements to copy: 16
java.lang.IndexOutOfBoundsException: Wrong number of elements to copy: 16 at org.apache.harmony.awt.nativebridge.ByteBase.checkArraysBounds(ByteBase.java:1123) at org.apache.harmony.awt.nativebridge.ByteBase.get(ByteBase.java:172) at org.apache.harmony.awt.tests.nativebridge.PointerPointerTest.test_set(PointerPointerTest.java:55) at java.lang.reflect.VMReflection.invokeMethod(Native Method)
2)test_setAddress
Wrong number of elements to copy: 16
java.lang.IndexOutOfBoundsException: Wrong number of elements to copy: 16 at org.apache.harmony.awt.nativebridge.ByteBase.checkArraysBounds(ByteBase.java:1123) at org.apache.harmony.awt.nativebridge.ByteBase.get(ByteBase.java:172) at org.apache.harmony.awt.tests.nativebridge.PointerPointerTest.test_setAddress(PointerPointerTest.java:66) at java.lang.reflect.VMReflection.invokeMethod(Native Method)
I've added the test to the exclude list. Could you investigate?
Thanks,
Stepan.
> [classlib][awt] PointerPointer's methods set/get, set/getAddress don't use pointer size.
> ----------------------------------------------------------------------------------------
>
> Key: HARMONY-2547
> URL: https://issues.apache.org/jira/browse/HARMONY-2547
> Project: Harmony
> Issue Type: Bug
> Components: Classlib
> Reporter: Oleg Khaschansky
> Assigned To: Alexei Zakharov
> Attachments: harmony-2547-test.patch, harmony-2547.patch
>
>
> The following methods of org.apache.harmony.awt.nativebridge.PointerPointer
> don't multiply index to elemnt size PP_SIZE_FACTOR: set(int, VoidPointer),
> get(int), setAddress(int, long), getAddress(int).
> Here's a small testcase:
> import org.apache.harmony.awt.nativebridge.NativeBridge;
> import org.apache.harmony.awt.nativebridge.PointerPointer;
> public class PointerPointerTest {
> public static void main(String[] args) {
> PointerPointer p = NativeBridge.getInstance().createPointerPointer(2, false);
> p.setAddress(0, 0xFFFFFFFF);
> System.out.println("*(p+1) = " + Long.toHexString(p.getAddress(1)) + " should be 0");
> }
> }
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Updated: (HARMONY-2547) [classlib][awt] PointerPointer's
methods set/get, set/getAddress don't use pointer size.
Posted by "Oleg Khaschansky (JIRA)" <ji...@apache.org>.
[ http://issues.apache.org/jira/browse/HARMONY-2547?page=all ]
Oleg Khaschansky updated HARMONY-2547:
--------------------------------------
Attachment: harmony-2547.patch
Proposed patch.
> [classlib][awt] PointerPointer's methods set/get, set/getAddress don't use pointer size.
> ----------------------------------------------------------------------------------------
>
> Key: HARMONY-2547
> URL: http://issues.apache.org/jira/browse/HARMONY-2547
> Project: Harmony
> Issue Type: Bug
> Components: Classlib
> Reporter: Oleg Khaschansky
> Attachments: harmony-2547.patch
>
>
> The following methods of org.apache.harmony.awt.nativebridge.PointerPointer
> don't multiply index to elemnt size PP_SIZE_FACTOR: set(int, VoidPointer),
> get(int), setAddress(int, long), getAddress(int).
> Here's a small testcase:
> import org.apache.harmony.awt.nativebridge.NativeBridge;
> import org.apache.harmony.awt.nativebridge.PointerPointer;
> public class PointerPointerTest {
> public static void main(String[] args) {
> PointerPointer p = NativeBridge.getInstance().createPointerPointer(2, false);
> p.setAddress(0, 0xFFFFFFFF);
> System.out.println("*(p+1) = " + Long.toHexString(p.getAddress(1)) + " should be 0");
> }
> }
--
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