On Wed, 2014-10-08 at 09:40 +0000, Thiemo van Engelen wrote:
>
> Please comment on the functionality and the patch and what I should do
> to get this integrated into connman. Should I post it on the mailing
> list or also send it directly to Patrik (or someone else)?
Thanks for pinging. I forgot to ask which version of ConnMan you were
using, but that does not really matter.
Noticed with Jukka that the last error is saved to file. That by itself
is not a problem, except that when the service is created and the
defaults loaded from file, on the first connect...
> diff --git a/src/service.c b/src/service.c
> index 895387d..70381c4 100644
> --- a/src/service.c
> +++ b/src/service.c
> @@ -5842,8 +5842,8 @@ static int service_connect(struct connman_service
> *service)
> if (!service->wps ||
>
> !connman_network_get_bool(service->network, "WiFi.UseWPS"))
> return -ENOKEY;
> - } else if (service->error ==
> - CONNMAN_SERVICE_ERROR_INVALID_KEY)
> + } else if (service->error ==
> CONNMAN_SERVICE_ERROR_INVALID_KEY &&
> +
> !connman_setting_get_bool("IgnoreInvalidKey"))
...the code interprets the error read from file to be a current one.
Which is a bug. But meanwhile this has been fixed with a few commits
leading to 6b70c54a69dfe670eba8c5d3d43ecf24be0e1e51, which actually
fixed a bit of a different problem. So as of that commit, a saved error
does not cause the first connect to fail. And after that commit,
service->error will never be set so the check is now unnecessary and
should be removed.
If I read the tea leaves correct, all should work fine in current
upstream. Hope this helps. Can we have a Bush Baby for testing?
Cheers,
Patrik
_______________________________________________
connman mailing list
[email protected]
https://lists.connman.net/mailman/listinfo/connman