]> git.ipfire.org Git - thirdparty/iw.git/commitdiff
iw: free memory on scan parse errors
authorAmit Khatri <amit.khatri@samsung.com>
Fri, 26 Jun 2015 09:02:36 +0000 (09:02 +0000)
committerJohannes Berg <johannes.berg@intel.com>
Thu, 13 Aug 2015 08:50:45 +0000 (10:50 +0200)
Signed-off-by: Amit Khatri <amit.khatri@samsung.com>
Signed-off-by: Rahul Jain <rahul.jain@samsung.com>
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
scan.c

diff --git a/scan.c b/scan.c
index 5f0a2a9fd469aeaafa89b9fbdbaef7bcca722590..e98f5d72e6db33000ff86253a4e49d6f94490eef 100644 (file)
--- a/scan.c
+++ b/scan.c
@@ -408,6 +408,8 @@ static int handle_scan(struct nl80211_state *state,
                                break;
                        }
                case DONE:
+                       nlmsg_free(ssids);
+                       nlmsg_free(freqs);
                        return 1;
                case FREQ:
                        freq = strtoul(argv[i], &eptr, 10);