RFC: fix problems in jforex charts

Deepak Bhole dbhole at redhat.com
Tue Feb 28 07:04:34 PST 2012


* Andrew Haley <aph at redhat.com> [2012-02-28 04:30]:
> On 02/27/2012 09:02 PM, Omair Majid wrote:
> > diff --git a/plugin/icedteanp/java/sun/applet/GetMemberPluginCallRequest.java b/plugin/icedteanp/java/sun/applet/GetMemberPluginCallRequest.java
> > --- a/plugin/icedteanp/java/sun/applet/GetMemberPluginCallRequest.java
> > +++ b/plugin/icedteanp/java/sun/applet/GetMemberPluginCallRequest.java
> > @@ -50,7 +50,7 @@
> >          String[] args = message.split(" ");
> >          // FIXME: Is it even possible to distinguish between null and void
> >          // here?
> > -        if (args[3] != "null" && args[3] != "void")
> > +        if (args.length > 3 && args[3] != "null" && args[3] != "void")
> >              object = AppletSecurityContextManager.getSecurityContext(0).getObject(Integer.parseInt(args[3]));
> >          setDone(true);
> >      }
> 
> This is rather horrible.
> 
> It would be much nicer to write a method that trims garbage args
> and then check the length of the trimmed arg list.
> 

This patch will not be going in.

This would be my bad. The above fix is in receiver code and I thought it
was needed on receiver side because sender was now doing the right thing
(as opposed to before) after Thomas's patch. Turns out though that the
sender is wrong after all.

I have posted a separate patch to sender (C++ side) to ensure that it
always sends a message with length >= 4.

Cheers,
Deepak



More information about the distro-pkg-dev mailing list