aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorAleksander Morgado <aleksander@aleksander.es>2017-02-01 10:37:32 +0100
committerAleksander Morgado <aleksander@aleksander.es>2017-02-01 22:59:22 +0100
commit4341368dec4635a0e438cad6d15a14bd6444e0fb (patch)
tree5966b118a82fb03343fbb8b3785e6d50cb41cbea
parent86453783cb7e63f2a1ac0e413542928e304e60a4 (diff)
downloadexternal_libqmi-4341368dec4635a0e438cad6d15a14bd6444e0fb.zip
external_libqmi-4341368dec4635a0e438cad6d15a14bd6444e0fb.tar.gz
external_libqmi-4341368dec4635a0e438cad6d15a14bd6444e0fb.tar.bz2
qmi-firmware-update: plug several memleaks
-rw-r--r--src/qmi-firmware-update/qfu-image-cwe.c1
-rw-r--r--src/qmi-firmware-update/qfu-updater.c2
-rw-r--r--src/qmi-firmware-update/qfu-utils.c1
3 files changed, 4 insertions, 0 deletions
diff --git a/src/qmi-firmware-update/qfu-image-cwe.c b/src/qmi-firmware-update/qfu-image-cwe.c
index f76afda..06549c8 100644
--- a/src/qmi-firmware-update/qfu-image-cwe.c
+++ b/src/qmi-firmware-update/qfu-image-cwe.c
@@ -466,6 +466,7 @@ load_image_info (QfuImageCwe *self,
g_debug ("[qfu-image-cwe] %simage at offset %" G_GOFFSET_FORMAT " is valid", parent_prefix, tested_offset);
walker = g_seekable_tell (G_SEEKABLE (input_stream));
}
+ g_free (image_prefix);
/* Finally, seek to just after this image */
if (!g_seekable_seek (G_SEEKABLE (input_stream), image_end_offset, G_SEEK_SET, cancellable, error)) {
diff --git a/src/qmi-firmware-update/qfu-updater.c b/src/qmi-firmware-update/qfu-updater.c
index 5299836..229b56d 100644
--- a/src/qmi-firmware-update/qfu-updater.c
+++ b/src/qmi-firmware-update/qfu-updater.c
@@ -980,6 +980,8 @@ run_context_step_set_firmware_preference (GTask *task)
g_free (modem_image_id.build_id);
g_array_unref (pri_image_id.unique_id);
g_free (pri_image_id.build_id);
+
+ qmi_message_dms_set_firmware_preference_input_unref (input);
}
static gboolean
diff --git a/src/qmi-firmware-update/qfu-utils.c b/src/qmi-firmware-update/qfu-utils.c
index ba24a0b..9977f1f 100644
--- a/src/qmi-firmware-update/qfu-utils.c
+++ b/src/qmi-firmware-update/qfu-utils.c
@@ -661,6 +661,7 @@ power_cycle_step_ready (QmiClientDms *qmi_client,
}
g_debug ("[qfu,utils] operating mode set successfully...");
+ qmi_message_dms_set_operating_mode_output_unref (output);
/* Go on */
ctx->step++;