Signed-off-by: Andy Grover <agro...@redhat.com>
---
 usr/iscsiadm.c | 5 ++---
 1 file changed, 2 insertions(+), 3 deletions(-)

diff --git a/usr/iscsiadm.c b/usr/iscsiadm.c
index f886d39..0cdc1bb 100644
--- a/usr/iscsiadm.c
+++ b/usr/iscsiadm.c
@@ -2211,7 +2211,7 @@ static void print_host_stats(struct 
iscsi_offload_host_stats *host_stats)
 static int exec_host_stats_op(int op, int info_level, uint32_t host_no)
 {
        struct iscsi_transport *t = NULL;
-       char *req_buf;
+       char *req_buf = NULL;
        int rc = ISCSI_SUCCESS;
        int fd = 0, buf_size = 0;
 
@@ -2251,8 +2251,7 @@ static int exec_host_stats_op(int op, int info_level, 
uint32_t host_no)
        ipc->ctldev_close();
 
 exit_host_stats:
-       if (req_buf)
-               free(req_buf);
+       free(req_buf);
        return rc;
 }
 
-- 
1.9.3

-- 
You received this message because you are subscribed to the Google Groups 
"open-iscsi" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to open-iscsi+unsubscr...@googlegroups.com.
To post to this group, send email to open-iscsi@googlegroups.com.
Visit this group at http://groups.google.com/group/open-iscsi.
For more options, visit https://groups.google.com/d/optout.

Reply via email to