Alexey Varlamov wrote:
2006/11/8, Oliver Deakin <[EMAIL PROTECTED]>:

Evgueni Brevnov wrote:
> On 11/8/06, Tim Ellison <[EMAIL PROTECTED]> wrote:
>> Oliver Deakin wrote:
>> <SNIP!>
>> > 2) The bogus "FAILED to invoke JVM" message.
>> > Looks like this is coming from the launcher (Im running
>> > Harmony + IBM VME).
>> > It appears that this happens because in main_runJavaMain
>> > (in the launcher main.c) after we make the CallStaticVoidMethod()
>> > call to run main, we do the following:
>> >
>> > if ((*env)->ExceptionCheck (env))
>> >    {
>> >      if (rc == 0)
>> >        rc = 100;
>> >    }
>> >
>> > which causes a return code of 100 to be passed back to
>> > gpProtectedMain() via the invocation() function, where it is used
>> > in the following way:
>> >
>> > if (invocation(...))
>> >    {
>> >      hytty_printf (PORTLIB, "FAILED to invoke JVM.\n");
>> >      goto bail;
>> >    }
>> >
>> > I imagine this misleading message also appears with DRLVM?
>> > I'm not setup at the moment to test it.
>> > Is there a reason we set the return code to 100 if there's an
>> > unhandled exception?
>>
>> I'll leave that one for the person who changed the code ;-)
>
> Yes, I also observed such message when running with DRLVM. Actually,
> there is  the patch already which fixes the problem with the error
> code returned by the launcher to OS. Moreover this patch removes the
> misleading message as well. Look at
> http://issues.apache.org/jira/browse/HARMONY-2006 ....
> classlib_exit_code.patch

Hi Evgueni,

I have taken a look at the launcher patch for H2006, and for the most
part it looks good. The only thing that caught my eye was that you
have commented out the "FAILED to invoke JVM" error message completely.
This is still a useful message in some cases (where the VM fails to launch)
but should not be printed for cases where the VM has actually executed.
So perhaps we need a check here for the return value of invocation to
determine whether to print the message or not?

Sounds reasonable - VM should not die silently. Please go for it.

Done in r472533.

Regards,
Oliver


--
Regards,
Alexey


Regards,
Oliver
>
> Thanks
> Evgueni
>
>>
>> Regards,
>> Tim
>>
>> --
>>
>> Tim Ellison ([EMAIL PROTECTED])
>> IBM Java technology centre, UK.
>>
>

--
Oliver Deakin
IBM United Kingdom Limited




--
Oliver Deakin
IBM United Kingdom Limited

Reply via email to