Potential bug in the Java binding

asked 2014-04-02 06:17:40 -0700

PierreR gravatar image

In ProxyBusObject.java, the constructor is looking for a busConnectionLost method :

    try {
        busConnectionLost = 
            getClass().getDeclaredMethod("busConnectionLost", String.class);
    } catch (NoSuchMethodException ex) {
        /* This will not happen */

I'm quite confused by this code : there is no busConnectionLost in the ProxyBusObject and we clearly go (silently !) in the catch block (I've tested it). On the other hand, there is a busConnectionLostfield, which does not seem to be used. Is that an error or am I missing some subtle implementation trick ?

edit retag flag offensive close merge delete

1 answer

Sort by ยป oldest newest most voted

answered 2014-04-02 14:03:17 -0700

This code predates sessions in AllJoyn. It looks like it failed to get removed when we added the APIs for sessions to the Java binding. So no subtle imlementation trick, just dead code that should've been removed a long time ago.

edit flag offensive delete publish link more



ok, that's what I thought, just wanted to be sure. So the BusConnectionLost field is useless as well ? Should I submit a bug in JIRA ? Actually I don't really see a buggy behavior but I'm wondering how the conection lost event is notified then.

PierreR ( 2014-04-03 00:27:55 -0700 )edit

Yep, feel free to submit a bug or a patch.

tmalsbar ( 2014-04-03 09:19:29 -0700 )edit

@PierreR if you feel this answered you question please remember to mark it a correct so @tmalsbar will get karma for helping you out.

georgen ( 2014-04-04 08:41:43 -0700 )edit

yes sure, sorry I forgot it. I'll probably also enventually submit a patch but with my work on a dynamic binding, my source tree is not in a good state for that now.

PierreR ( 2014-04-04 23:30:27 -0700 )edit
Login/Signup to Answer

Question Tools

1 follower


Asked: 2014-04-02 06:17:40 -0700

Seen: 104 times

Last updated: Apr 02 '14