You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@harmony.apache.org by "Ivan Volosyuk (JIRA)" <ji...@apache.org> on 2007/01/11 18:07:27 UTC
[jira] Updated: (HARMONY-2976) [drlvm][interpreter] VM crashes
instead of throwing NullPointerException
[ https://issues.apache.org/jira/browse/HARMONY-2976?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Ivan Volosyuk updated HARMONY-2976:
-----------------------------------
Attachment: fix-2976.diff
> [drlvm][interpreter] VM crashes instead of throwing NullPointerException
> -------------------------------------------------------------------------
>
> Key: HARMONY-2976
> URL: https://issues.apache.org/jira/browse/HARMONY-2976
> Project: Harmony
> Issue Type: Bug
> Components: DRLVM
> Environment: Windows and Linux
> Reporter: Vera Petrashkova
> Attachments: fix-2976.diff
>
>
> [drlvm][interpreter] VM crashes instead of throwing NullPointerException if null object is used for synchronization
> The following test demonstrates that interpreter crashes when object which was not initialized (null) is used for synchronization.
> -----------------NullSynchTest.java---------------
> public class NullSyncTest {
> static Object objNull = null;
> public static void main(String[] args) {
> try {
> syncNull();
> System.out.println("Test failed: NullPointerException should be thrown");
> } catch (NullPointerException e) {
> System.out.println("Test passed: " + e);
> } catch (Throwable e) {
> e.printStackTrace();
> System.out.println("Test failed: unexpected " + e);
> }
> }
> public static void syncNull() {
> synchronized (objNull) {
> objNull = new Object();
> }
> }
> }
> ------------------------
> On Windows this test reports
> An unhandled error (4) has occurred.
> HyGeneric_Signal_Number=00000004
> ExceptionCode=c0000005
> ExceptionAddress=10003974
> ContextFlags=0001003f
> Handler1=00401100
> Handler2=111072C0
> InaccessibleAddress=00000004
> EDI=020A86E0
> ESI=0013F6DC
> EAX=00000004
> EBX=0013F718
> ECX=00000000
> EDX=00000004
> EIP=10003974
> ESP=0013F520
> EBP=0013F634
> Module= ...HYTHR.dll
> On Linux this test finishes with Segmentation fault
> On Jitrino this test passes.
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: https://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira