summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorPeter Schiffer <pschiffe@redhat.com>2014-02-04 13:31:02 +0100
committerPeter Schiffer <pschiffe@redhat.com>2014-02-04 13:31:02 +0100
commit256f3391536973eb610199f5c9628232b5953a21 (patch)
tree80df4697c47f96f4acd2c53333688d1161bcd306
parent0bcf64c82f3fe5083b3eb48379146d782c2d2106 (diff)
downloadopenlmi-providers-256f3391536973eb610199f5c9628232b5953a21.tar.gz
openlmi-providers-256f3391536973eb610199f5c9628232b5953a21.tar.xz
openlmi-providers-256f3391536973eb610199f5c9628232b5953a21.zip
Hardware: fixed memory leak
-rw-r--r--src/hardware/lsblk.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/src/hardware/lsblk.c b/src/hardware/lsblk.c
index 4a06f2c..512ccad 100644
--- a/src/hardware/lsblk.c
+++ b/src/hardware/lsblk.c
@@ -165,6 +165,8 @@ short lsblk_get_hdds(LsblkHdd **hdds, unsigned *hdds_nb)
}
capacity = round(size * multiplier);
}
+ free(buf);
+ buf = NULL;
}
init_lsblkhdd_struct(&(*hdds)[curr_hdd]);