From f6c2a8d9b7efc6afd9a91acbf8af8ff39a4c5bb2 Mon Sep 17 00:00:00 2001 From: Alexis Date: Fri, 23 Nov 2018 17:42:26 +0100 Subject: [PATCH] fix(network): free the message instead of the socket --- src/modules/network.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/modules/network.cpp b/src/modules/network.cpp index 979cb90..3889403 100644 --- a/src/modules/network.cpp +++ b/src/modules/network.cpp @@ -429,7 +429,7 @@ auto waybar::modules::Network::getInfo() -> void { struct nl_msg* nl_msg = nlmsg_alloc(); if (nl_msg == nullptr) { - nl_socket_free(sk_); + nlmsg_free(nl_msg); return; } if (genlmsg_put(nl_msg, NL_AUTO_PORT, NL_AUTO_SEQ, nl80211_id_, 0, NLM_F_DUMP,