Updated: October 28, 2024 |
Receive an event message
#include <wpa_ctrl.h>
int wpa_ctrl_recv(struct wpa_ctrl *ctrl, char *reply, size_t *reply_len)
This function receives an event message from the control connection. The message is written as a text string to the buffer in reply and reply_len is set to the actual message length. For details on how to parse the message contents, see the WPA events reference.
This function can be used only for event messages, meaning wpa_ctrl_attach() must have been used to register the caller as an event monitor.
0 on success, -1 on failure