Glen,

On Wednesday 01 August 2007 13:44, Glen Mazza wrote:
> > +                String interfaceName = jp.getInterfaceClass();
> > (A)                 JavaInterface intf =
> > interfaces.get(interfaceName); (B)+                if (intf == null)
> > {
> > (C)+                    interfaceName = jp.getPortType();
> > (D)+                    intf = interfaces.get(interfaceName);
> > (E)+                }
>
> There may be a bug here (and in the two cases below).  Namely, I can't
> see the reason for statement (D) above.  If (A) results in intf being
> set to NULL, lines (B) - (E) will be activated.  But how can statement
> (D) set intf to anything but null again--statement (C) has no side
> effect in adding interface names to the interfaces object.

Line (C) results in a new value for interfaceName which results in a new 
value being used to lookup stuff from the interfaces Map.   The map 
doesn't change, the lookup key does.


-- 
J. Daniel Kulp
Principal Engineer
IONA
P: 781-902-8727    C: 508-380-7194
[EMAIL PROTECTED]
http://www.dankulp.com/blog

Reply via email to