Revert "wifi: fix entering an endless loop"
This reverts commit 84403ab84a
.
It appears we want to loop until one of the callback says we're
done, while this patch would exit too early (possibly before we'd
received a reply) since nl_recvmsgs() returns 0 on success. What
we really want do do here is wait for one of the callbacks we've
registered to tell us that they've successfully handled the message
and gotten a reply.
This commit is contained in:
@@ -127,7 +127,7 @@ _nl80211_send_and_recv (struct nl_sock *nl_sock,
|
|||||||
nl_cb_set (cb, NL_CB_VALID, NL_CB_CUSTOM, valid_handler, valid_data);
|
nl_cb_set (cb, NL_CB_VALID, NL_CB_CUSTOM, valid_handler, valid_data);
|
||||||
|
|
||||||
while (err > 0)
|
while (err > 0)
|
||||||
err = nl_recvmsgs (nl_sock, cb);
|
nl_recvmsgs (nl_sock, cb);
|
||||||
|
|
||||||
out:
|
out:
|
||||||
nl_cb_put (cb);
|
nl_cb_put (cb);
|
||||||
|
Reference in New Issue
Block a user