wiphy: Return an error if agent request fails

If there is no agent registered, then the caller should not be hanging
without a response forever.
This commit is contained in:
Denis Kenzior 2015-03-20 15:42:50 -05:00
parent 141a1831c0
commit 842eb643eb
1 changed files with 4 additions and 0 deletions

View File

@ -338,6 +338,10 @@ static struct l_dbus_message *network_connect(struct l_dbus *dbus,
network->object_path,
passphrase_callback,
network);
if (!network->agent_request)
return dbus_error_no_agent(message);
break;
}