Hi Jaakko,
On ma, 2015-07-27 at 15:32 +0300, Jaakko Hannikainen wrote:
> Data might be NULL if called from vpn_died, so check it and do
> nothing if it is NULL.
> ---
> vpn/plugins/vpn.c | 2 ++
> 1 file changed, 2 insertions(+)
>
> diff --git a/vpn/plugins/vpn.c b/vpn/plugins/vpn.c
> index 60954be..1b5af6e 100644
> --- a/vpn/plugins/vpn.c
> +++ b/vpn/plugins/vpn.c
> @@ -199,6 +199,8 @@ static int vpn_set_state(struct vpn_provider *provider,
> enum vpn_provider_state state)
> {
> struct vpn_data *data = vpn_provider_get_data(provider);
> + if (!data)
> + return -EINVAL;
>
> switch (state) {
> case VPN_PROVIDER_STATE_UNKNOWN:
Good catch, ACK to this.
Cheers,
Jukka
_______________________________________________
connman mailing list
[email protected]
https://lists.connman.net/mailman/listinfo/connman