lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-Id: <20171227075759.15289-10-leon@kernel.org>
Date:   Wed, 27 Dec 2017 09:57:58 +0200
From:   Leon Romanovsky <leon@...nel.org>
To:     David Ahern <dsahern@...il.com>
Cc:     Leon Romanovsky <leonro@...lanox.com>,
        netdev <netdev@...r.kernel.org>,
        Stephen Hemminger <stephen@...workplumber.org>
Subject: [PATCH iproute2-next 09/10] rdma: Rename rd_free_devmap to be rd_free

From: Leon Romanovsky <leonro@...lanox.com>

Signed-off-by: Leon Romanovsky <leonro@...lanox.com>
---
 rdma/rdma.c  | 3 +--
 rdma/rdma.h  | 2 +-
 rdma/utils.c | 3 ++-
 3 files changed, 4 insertions(+), 4 deletions(-)

diff --git a/rdma/rdma.c b/rdma/rdma.c
index a05a2fb6..0e8fd688 100644
--- a/rdma/rdma.c
+++ b/rdma/rdma.c
@@ -74,8 +74,7 @@ static void rd_cleanup(struct rd *rd)
 {
 	if (rd->json_output)
 		jsonw_destroy(&rd->jw);
-	free(rd->buff);
-	rd_free_devmap(rd);
+	rd_free(rd);
 }
 
 int main(int argc, char **argv)
diff --git a/rdma/rdma.h b/rdma/rdma.h
index b85e3748..afc0e413 100644
--- a/rdma/rdma.h
+++ b/rdma/rdma.h
@@ -73,11 +73,11 @@ int cmd_dev(struct rd *rd);
 int cmd_link(struct rd *rd);
 int rd_exec_cmd(struct rd *rd, const struct rd_cmd *c, const char *str);
 int rd_exec_dev(struct rd *rd, int (*cb)(struct rd *rd));
+void rd_free(struct rd *rd);
 
 /*
  * Device manipulation
  */
-void rd_free_devmap(struct rd *rd);
 struct dev_map *dev_map_lookup(struct rd *rd, bool allow_port_index);
 
 /*
diff --git a/rdma/utils.c b/rdma/utils.c
index c1069967..d7284801 100644
--- a/rdma/utils.c
+++ b/rdma/utils.c
@@ -144,10 +144,11 @@ int rd_dev_init_cb(const struct nlmsghdr *nlh, void *data)
 	return MNL_CB_OK;
 }
 
-void rd_free_devmap(struct rd *rd)
+void rd_free(struct rd *rd)
 {
 	if (!rd)
 		return;
+	free(rd->buff);
 	dev_map_cleanup(rd);
 }
 
-- 
2.15.1

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ