Hi,
On Wed, 2015-10-14 at 17:49 +1100, Craig McQueen wrote:
> I've been looking into extending connmanctl's functionality with
> configuration for the net.connman.Clock API. I've been developing a
> command that can set clock properties, similar to the existing
> "config" command.
>
> I've noticed that when multiple parameters are set, then the 'return'
> function is often not called. E.g.:
>
> connmanctl config ethernet_4a4a5a6a3a0a_cable --ipv6 off
> --autoconnect yes --timeservers 0.pool.ntp.org
>
> In this case, it sends 3 D-Bus commands, and config_return() should be
> called for each response. But it is likely to shutdown before calling
> config_return() all three times.
>
> I see that dbus_method_reply() calls __connmanctl_quit(). That seems
> to be implicated in this. It seems the logic is to initiate shutdown
> after the response is received for the first D-Bus message sent.
The logic has a bug here. It would be best if connmanctl exits after all
the method calls have completed. You are always free to send a patch for
this or implement it properly for Clock API commands, if you intend to
send patches for supporting that.
Cheers,
Patrik
_______________________________________________
connman mailing list
[email protected]
https://lists.connman.net/mailman/listinfo/connman