mirror of
https://gitlab.freedesktop.org/NetworkManager/NetworkManager.git
synced 2026-04-18 08:30:41 +02:00
platform/wifi: fix memleak in _nl80211_send_and_recv()
The callers expect _nl80211_send_and_recv() to free @msg.
This was broken by the previous commit, which wrongly removed
the nm_auto_nlmsg cleanup attribute.
Fix the compiler warning differently.
Fixes: d7108d9362
This commit is contained in:
parent
d7108d9362
commit
a79e6b3b45
1 changed files with 2 additions and 1 deletions
|
|
@ -185,10 +185,11 @@ nl80211_alloc_msg (WifiDataNl80211 *nl80211, guint32 cmd, guint32 flags)
|
|||
/* NOTE: this function consumes 'msg' */
|
||||
static int
|
||||
_nl80211_send_and_recv (struct nl_sock *nl_sock,
|
||||
struct nl_msg *msg,
|
||||
struct nl_msg *inmsg,
|
||||
int (*valid_handler) (struct nl_msg *, void *),
|
||||
void *valid_data)
|
||||
{
|
||||
nm_auto_nlmsg struct nl_msg *msg = inmsg;
|
||||
int err;
|
||||
int done = 0;
|
||||
const struct nl_cb cb = {
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue