Compare commits
No commits in common. 'c10-beta' and 'c9' have entirely different histories.
@ -1 +1 @@
|
||||
SOURCES/libqmi-1.34.0.tar.bz2
|
||||
SOURCES/libqmi-1.32.2.tar.bz2
|
||||
|
@ -1 +1 @@
|
||||
e334503461000fccf5788f45c6ac0050b3ff2bad SOURCES/libqmi-1.34.0.tar.bz2
|
||||
3bc82111a621e684dd61f26ea0cc7cc54cf09c9f SOURCES/libqmi-1.32.2.tar.bz2
|
||||
|
@ -1,28 +0,0 @@
|
||||
From a87202030adf1fc1c1082a20e778ca7eaf46bcca Mon Sep 17 00:00:00 2001
|
||||
From: Lubomir Rintel <lkundrak@v3.sk>
|
||||
Date: Thu, 23 May 2024 10:02:20 +0200
|
||||
Subject: [PATCH 1/9] test-fixture: assert the service type index fits into
|
||||
service_info[]
|
||||
|
||||
Largest QmiService is QMI_SERVICE_SSC=0x190 (400 dec) whereas
|
||||
service_info[] has 255 elements. This made a static analyzer
|
||||
frown. Make it happy again!
|
||||
---
|
||||
src/libqmi-glib/test/test-fixture.c | 1 +
|
||||
1 file changed, 1 insertion(+)
|
||||
|
||||
diff --git a/src/libqmi-glib/test/test-fixture.c b/src/libqmi-glib/test/test-fixture.c
|
||||
index cfbc2b49..32049c67 100644
|
||||
--- a/src/libqmi-glib/test/test-fixture.c
|
||||
+++ b/src/libqmi-glib/test/test-fixture.c
|
||||
@@ -51,6 +51,7 @@ device_allocate_client_ready (QmiDevice *device,
|
||||
|
||||
service = qmi_client_get_service (client);
|
||||
g_assert (service > QMI_SERVICE_CTL);
|
||||
+ g_assert ((unsigned)service < G_N_ELEMENTS (fixture->service_info));
|
||||
fixture->service_info[service].client = client;
|
||||
fixture->service_info[service].transaction_id = 0x0001;
|
||||
test_fixture_loop_stop (fixture);
|
||||
--
|
||||
2.45.2
|
||||
|
@ -1,28 +0,0 @@
|
||||
From 489dde670fd2b5e6721876279dce03f3a4002d44 Mon Sep 17 00:00:00 2001
|
||||
From: Lubomir Rintel <lkundrak@v3.sk>
|
||||
Date: Thu, 23 May 2024 10:46:56 +0200
|
||||
Subject: [PATCH 2/9] swi-update: close the file handle even if it's zero
|
||||
|
||||
Technically, zero is a perfectly fine file descriptor for open() to
|
||||
return in case the parent process feels frivolous and chooses to
|
||||
close stdin.
|
||||
---
|
||||
utils/swi-update.c | 2 +-
|
||||
1 file changed, 1 insertion(+), 1 deletion(-)
|
||||
|
||||
diff --git a/utils/swi-update.c b/utils/swi-update.c
|
||||
index 609c5baa..61cd71c9 100644
|
||||
--- a/utils/swi-update.c
|
||||
+++ b/utils/swi-update.c
|
||||
@@ -867,7 +867,7 @@ static int download_image(int serfd, char *buf, const char *image)
|
||||
fprintf(stderr, "\n");
|
||||
|
||||
out:
|
||||
- if (imgfd > 0)
|
||||
+ if (imgfd >= 0)
|
||||
close(imgfd);
|
||||
return ret;
|
||||
}
|
||||
--
|
||||
2.45.2
|
||||
|
@ -1,162 +0,0 @@
|
||||
From 6de3d5c2481b219271ee747739995266d5f76ba0 Mon Sep 17 00:00:00 2001
|
||||
From: Lubomir Rintel <lkundrak@v3.sk>
|
||||
Date: Thu, 23 May 2024 10:06:47 +0200
|
||||
Subject: [PATCH 3/9] qmicli: avoid leaking the input messages
|
||||
|
||||
In various places in we follow this pattern:
|
||||
|
||||
input = qmi_message_uim_power_on_sim_input_new ();
|
||||
if (bad arguments) {
|
||||
complain();
|
||||
return; // leak input
|
||||
}
|
||||
issue_message(input);
|
||||
|
||||
Let's, instead, always do the argument sanity checks before allocating
|
||||
the message, to avoid leaking the message.
|
||||
---
|
||||
src/qmicli/qmicli-uim.c | 8 ++++----
|
||||
src/qmicli/qmicli-wds.c | 31 +++++++++++++++++++++----------
|
||||
2 files changed, 25 insertions(+), 14 deletions(-)
|
||||
|
||||
diff --git a/src/qmicli/qmicli-uim.c b/src/qmicli/qmicli-uim.c
|
||||
index e344a682..2238c55b 100644
|
||||
--- a/src/qmicli/qmicli-uim.c
|
||||
+++ b/src/qmicli/qmicli-uim.c
|
||||
@@ -849,13 +849,13 @@ power_on_sim_input_create (const gchar *slot_str)
|
||||
guint slot;
|
||||
GError *error = NULL;
|
||||
|
||||
- input = qmi_message_uim_power_on_sim_input_new ();
|
||||
-
|
||||
if (!qmicli_read_uint_from_string (slot_str, &slot) || (slot > G_MAXUINT8)) {
|
||||
g_printerr ("error: invalid slot number\n");
|
||||
return NULL;
|
||||
}
|
||||
|
||||
+ input = qmi_message_uim_power_on_sim_input_new ();
|
||||
+
|
||||
if (!qmi_message_uim_power_on_sim_input_set_slot (input, slot, &error)) {
|
||||
g_printerr ("error: could not create SIM power on input: %s\n", error->message);
|
||||
g_error_free (error);
|
||||
@@ -907,13 +907,13 @@ power_off_sim_input_create (const gchar *slot_str)
|
||||
guint slot;
|
||||
GError *error = NULL;
|
||||
|
||||
- input = qmi_message_uim_power_off_sim_input_new ();
|
||||
-
|
||||
if (!qmicli_read_uint_from_string (slot_str, &slot) || (slot > G_MAXUINT8)) {
|
||||
g_printerr ("error: invalid slot number\n");
|
||||
return NULL;
|
||||
}
|
||||
|
||||
+ input = qmi_message_uim_power_off_sim_input_new ();
|
||||
+
|
||||
if (!qmi_message_uim_power_off_sim_input_set_slot (input, slot, &error)) {
|
||||
g_printerr ("error: could not create SIM power off input: %s\n", error->message);
|
||||
g_error_free (error);
|
||||
diff --git a/src/qmicli/qmicli-wds.c b/src/qmicli/qmicli-wds.c
|
||||
index 66a9d7cd..0bae3b40 100644
|
||||
--- a/src/qmicli/qmicli-wds.c
|
||||
+++ b/src/qmicli/qmicli-wds.c
|
||||
@@ -3197,14 +3197,14 @@ qmicli_wds_run (QmiDevice *device,
|
||||
#if defined HAVE_QMI_MESSAGE_WDS_SET_IP_FAMILY
|
||||
if (set_ip_family_str) {
|
||||
QmiMessageWdsSetIpFamilyInput *input;
|
||||
+ QmiWdsIpFamily preference;
|
||||
|
||||
- input = qmi_message_wds_set_ip_family_input_new ();
|
||||
switch (atoi (set_ip_family_str)) {
|
||||
case 4:
|
||||
- qmi_message_wds_set_ip_family_input_set_preference (input, QMI_WDS_IP_FAMILY_IPV4, NULL);
|
||||
+ preference = QMI_WDS_IP_FAMILY_IPV4;
|
||||
break;
|
||||
case 6:
|
||||
- qmi_message_wds_set_ip_family_input_set_preference (input, QMI_WDS_IP_FAMILY_IPV6, NULL);
|
||||
+ preference = QMI_WDS_IP_FAMILY_IPV6;
|
||||
break;
|
||||
default:
|
||||
g_printerr ("error: unknown IP type '%s' (not 4 or 6)\n",
|
||||
@@ -3212,6 +3212,10 @@ qmicli_wds_run (QmiDevice *device,
|
||||
operation_shutdown (FALSE);
|
||||
return;
|
||||
}
|
||||
+
|
||||
+ input = qmi_message_wds_set_ip_family_input_new ();
|
||||
+ qmi_message_wds_set_ip_family_input_set_preference (input, preference, NULL);
|
||||
+
|
||||
g_debug ("Asynchronously set IP family...");
|
||||
qmi_client_wds_set_ip_family (client,
|
||||
input,
|
||||
@@ -3441,7 +3445,6 @@ qmicli_wds_run (QmiDevice *device,
|
||||
guint profile_index;
|
||||
|
||||
split = g_strsplit (delete_profile_str, ",", -1);
|
||||
- input = qmi_message_wds_delete_profile_input_new ();
|
||||
|
||||
if (g_strv_length (split) != 2) {
|
||||
g_printerr ("error: expected 2 arguments for delete profile command\n");
|
||||
@@ -3471,6 +3474,8 @@ qmicli_wds_run (QmiDevice *device,
|
||||
return;
|
||||
}
|
||||
|
||||
+ input = qmi_message_wds_delete_profile_input_new ();
|
||||
+
|
||||
qmi_message_wds_delete_profile_input_set_profile_identifier (input, profile_type, (guint8)profile_index, NULL);
|
||||
|
||||
g_strfreev (split);
|
||||
@@ -3490,12 +3495,12 @@ qmicli_wds_run (QmiDevice *device,
|
||||
#if defined HAVE_QMI_MESSAGE_WDS_GET_PROFILE_LIST && defined HAVE_QMI_MESSAGE_WDS_GET_PROFILE_SETTINGS
|
||||
if (get_profile_list_str) {
|
||||
QmiMessageWdsGetProfileListInput *input;
|
||||
+ QmiWdsProfileType profile_type;
|
||||
|
||||
- input = qmi_message_wds_get_profile_list_input_new ();
|
||||
if (g_str_equal (get_profile_list_str, "3gpp"))
|
||||
- qmi_message_wds_get_profile_list_input_set_profile_type (input, QMI_WDS_PROFILE_TYPE_3GPP, NULL);
|
||||
+ profile_type = QMI_WDS_PROFILE_TYPE_3GPP;
|
||||
else if (g_str_equal (get_profile_list_str, "3gpp2"))
|
||||
- qmi_message_wds_get_profile_list_input_set_profile_type (input, QMI_WDS_PROFILE_TYPE_3GPP2, NULL);
|
||||
+ profile_type = QMI_WDS_PROFILE_TYPE_3GPP2;
|
||||
else {
|
||||
g_printerr ("error: invalid profile type '%s'. Expected '3gpp' or '3gpp2'.'\n",
|
||||
get_profile_list_str);
|
||||
@@ -3503,6 +3508,9 @@ qmicli_wds_run (QmiDevice *device,
|
||||
return;
|
||||
}
|
||||
|
||||
+ input = qmi_message_wds_get_profile_list_input_new ();
|
||||
+ qmi_message_wds_get_profile_list_input_set_profile_type (input, profile_type, NULL);
|
||||
+
|
||||
g_debug ("Asynchronously get profile list...");
|
||||
qmi_client_wds_get_profile_list (ctx->client,
|
||||
input,
|
||||
@@ -3574,12 +3582,12 @@ qmicli_wds_run (QmiDevice *device,
|
||||
#if defined HAVE_QMI_MESSAGE_WDS_GET_DEFAULT_SETTINGS
|
||||
if (get_default_settings_str) {
|
||||
QmiMessageWdsGetDefaultSettingsInput *input;
|
||||
+ QmiWdsProfileType profile_type;
|
||||
|
||||
- input = qmi_message_wds_get_default_settings_input_new ();
|
||||
if (g_str_equal (get_default_settings_str, "3gpp"))
|
||||
- qmi_message_wds_get_default_settings_input_set_profile_type (input, QMI_WDS_PROFILE_TYPE_3GPP, NULL);
|
||||
+ profile_type = QMI_WDS_PROFILE_TYPE_3GPP;
|
||||
else if (g_str_equal (get_default_settings_str, "3gpp2"))
|
||||
- qmi_message_wds_get_default_settings_input_set_profile_type (input, QMI_WDS_PROFILE_TYPE_3GPP2, NULL);
|
||||
+ profile_type = QMI_WDS_PROFILE_TYPE_3GPP2;
|
||||
else {
|
||||
g_printerr ("error: invalid default type '%s'. Expected '3gpp' or '3gpp2'.'\n",
|
||||
get_default_settings_str);
|
||||
@@ -3587,6 +3595,9 @@ qmicli_wds_run (QmiDevice *device,
|
||||
return;
|
||||
}
|
||||
|
||||
+ input = qmi_message_wds_get_default_settings_input_new ();
|
||||
+ qmi_message_wds_get_default_settings_input_set_profile_type (input, profile_type, NULL);
|
||||
+
|
||||
g_debug ("Asynchronously get default settings...");
|
||||
qmi_client_wds_get_default_settings (ctx->client,
|
||||
input,
|
||||
--
|
||||
2.45.2
|
||||
|
@ -1,52 +0,0 @@
|
||||
From 71e28cdb5e203715f5b75ee2930faa0416579b3d Mon Sep 17 00:00:00 2001
|
||||
From: Lubomir Rintel <lkundrak@v3.sk>
|
||||
Date: Thu, 23 May 2024 10:33:46 +0200
|
||||
Subject: [PATCH 4/9] qmicli-dms: do not leak split[]
|
||||
|
||||
In various places we fail to free up whatever g_strsplit() returned in
|
||||
error handling paths. Let's use automatic pointers in those cases.
|
||||
---
|
||||
src/qmicli/qmicli-dms.c | 6 ++----
|
||||
1 file changed, 2 insertions(+), 4 deletions(-)
|
||||
|
||||
diff --git a/src/qmicli/qmicli-dms.c b/src/qmicli/qmicli-dms.c
|
||||
index 8108f0a6..1bea9ad4 100644
|
||||
--- a/src/qmicli/qmicli-dms.c
|
||||
+++ b/src/qmicli/qmicli-dms.c
|
||||
@@ -2070,14 +2070,13 @@ static QmiMessageDmsActivateManualInput *
|
||||
activate_manual_input_create (const gchar *str)
|
||||
{
|
||||
QmiMessageDmsActivateManualInput *input;
|
||||
- gchar **split;
|
||||
+ g_auto(GStrv) split = NULL;
|
||||
GError *error = NULL;
|
||||
gulong split_1_int;
|
||||
|
||||
split = g_strsplit (str, ",", -1);
|
||||
if (g_strv_length (split) != 4) {
|
||||
g_printerr ("error: incorrect number of arguments given\n");
|
||||
- g_strfreev (split);
|
||||
return NULL;
|
||||
}
|
||||
|
||||
@@ -2103,7 +2102,6 @@ activate_manual_input_create (const gchar *str)
|
||||
input = NULL;
|
||||
}
|
||||
|
||||
- g_strfreev(split);
|
||||
return input;
|
||||
}
|
||||
|
||||
@@ -3184,8 +3182,8 @@ get_stored_image (QmiClientDms *client,
|
||||
gpointer user_data)
|
||||
{
|
||||
GetStoredImageContext *operation_ctx;
|
||||
+ g_auto(GStrv) split = NULL;
|
||||
GTask *task;
|
||||
- gchar **split;
|
||||
guint i = 0;
|
||||
gint modem_index = -1;
|
||||
gint pri_index = -1;
|
||||
--
|
||||
2.45.2
|
||||
|
@ -1,156 +0,0 @@
|
||||
From b5a9b693d04d2236b24455249408432a02b89484 Mon Sep 17 00:00:00 2001
|
||||
From: Lubomir Rintel <lkundrak@v3.sk>
|
||||
Date: Thu, 23 May 2024 10:40:57 +0200
|
||||
Subject: [PATCH 5/9] qmicli-dms: use automatic pointers for split strings
|
||||
|
||||
Do it for consistence's sake but also because it's apparently an easy
|
||||
thing to mess up.
|
||||
|
||||
No change in behavior, purely a cosmetic change.
|
||||
---
|
||||
src/qmicli/qmicli-dms.c | 24 ++++++++----------------
|
||||
1 file changed, 8 insertions(+), 16 deletions(-)
|
||||
|
||||
diff --git a/src/qmicli/qmicli-dms.c b/src/qmicli/qmicli-dms.c
|
||||
index 1bea9ad4..d001656f 100644
|
||||
--- a/src/qmicli/qmicli-dms.c
|
||||
+++ b/src/qmicli/qmicli-dms.c
|
||||
@@ -941,7 +941,7 @@ static QmiMessageDmsUimSetPinProtectionInput *
|
||||
uim_set_pin_protection_input_create (const gchar *str)
|
||||
{
|
||||
QmiMessageDmsUimSetPinProtectionInput *input = NULL;
|
||||
- gchar **split;
|
||||
+ g_auto(GStrv) split = NULL;
|
||||
QmiDmsUimPinId pin_id;
|
||||
gboolean enable_disable;
|
||||
gchar *current_pin;
|
||||
@@ -970,7 +970,6 @@ uim_set_pin_protection_input_create (const gchar *str)
|
||||
input = NULL;
|
||||
}
|
||||
}
|
||||
- g_strfreev (split);
|
||||
|
||||
return input;
|
||||
}
|
||||
@@ -1030,7 +1029,7 @@ static QmiMessageDmsUimVerifyPinInput *
|
||||
uim_verify_pin_input_create (const gchar *str)
|
||||
{
|
||||
QmiMessageDmsUimVerifyPinInput *input = NULL;
|
||||
- gchar **split;
|
||||
+ g_auto(GStrv) split = NULL;
|
||||
QmiDmsUimPinId pin_id;
|
||||
gchar *current_pin;
|
||||
|
||||
@@ -1056,7 +1055,6 @@ uim_verify_pin_input_create (const gchar *str)
|
||||
input = NULL;
|
||||
}
|
||||
}
|
||||
- g_strfreev (split);
|
||||
|
||||
return input;
|
||||
}
|
||||
@@ -1116,7 +1114,7 @@ static QmiMessageDmsUimUnblockPinInput *
|
||||
uim_unblock_pin_input_create (const gchar *str)
|
||||
{
|
||||
QmiMessageDmsUimUnblockPinInput *input = NULL;
|
||||
- gchar **split;
|
||||
+ g_auto(GStrv) split = NULL;
|
||||
QmiDmsUimPinId pin_id;
|
||||
gchar *puk;
|
||||
gchar *new_pin;
|
||||
@@ -1145,7 +1143,6 @@ uim_unblock_pin_input_create (const gchar *str)
|
||||
input = NULL;
|
||||
}
|
||||
}
|
||||
- g_strfreev (split);
|
||||
|
||||
return input;
|
||||
}
|
||||
@@ -1205,7 +1202,7 @@ static QmiMessageDmsUimChangePinInput *
|
||||
uim_change_pin_input_create (const gchar *str)
|
||||
{
|
||||
QmiMessageDmsUimChangePinInput *input = NULL;
|
||||
- gchar **split;
|
||||
+ g_auto(GStrv) split = NULL;
|
||||
QmiDmsUimPinId pin_id;
|
||||
gchar *old_pin;
|
||||
gchar *new_pin;
|
||||
@@ -1234,7 +1231,6 @@ uim_change_pin_input_create (const gchar *str)
|
||||
input = NULL;
|
||||
}
|
||||
}
|
||||
- g_strfreev (split);
|
||||
|
||||
return input;
|
||||
}
|
||||
@@ -1567,7 +1563,7 @@ static QmiMessageDmsUimSetCkProtectionInput *
|
||||
uim_set_ck_protection_input_create (const gchar *str)
|
||||
{
|
||||
QmiMessageDmsUimSetCkProtectionInput *input = NULL;
|
||||
- gchar **split;
|
||||
+ g_auto(GStrv) split = NULL;
|
||||
QmiDmsUimFacility facility;
|
||||
gboolean enable_disable;
|
||||
gchar *key;
|
||||
@@ -1602,7 +1598,6 @@ uim_set_ck_protection_input_create (const gchar *str)
|
||||
}
|
||||
}
|
||||
}
|
||||
- g_strfreev (split);
|
||||
|
||||
return input;
|
||||
}
|
||||
@@ -1658,7 +1653,7 @@ static QmiMessageDmsUimUnblockCkInput *
|
||||
uim_unblock_ck_input_create (const gchar *str)
|
||||
{
|
||||
QmiMessageDmsUimUnblockCkInput *input = NULL;
|
||||
- gchar **split;
|
||||
+ g_auto(GStrv) split = NULL;
|
||||
QmiDmsUimFacility facility;
|
||||
gchar *key;
|
||||
|
||||
@@ -1684,7 +1679,6 @@ uim_unblock_ck_input_create (const gchar *str)
|
||||
input = NULL;
|
||||
}
|
||||
}
|
||||
- g_strfreev (split);
|
||||
|
||||
return input;
|
||||
}
|
||||
@@ -2234,7 +2228,7 @@ static QmiMessageDmsSetUserLockStateInput *
|
||||
set_user_lock_state_input_create (const gchar *str)
|
||||
{
|
||||
QmiMessageDmsSetUserLockStateInput *input = NULL;
|
||||
- gchar **split;
|
||||
+ g_auto(GStrv) split = NULL;
|
||||
gboolean enable_disable;
|
||||
gchar *code;
|
||||
|
||||
@@ -2261,7 +2255,6 @@ set_user_lock_state_input_create (const gchar *str)
|
||||
input = NULL;
|
||||
}
|
||||
}
|
||||
- g_strfreev (split);
|
||||
|
||||
return input;
|
||||
}
|
||||
@@ -2304,7 +2297,7 @@ static QmiMessageDmsSetUserLockCodeInput *
|
||||
set_user_lock_code_input_create (const gchar *str)
|
||||
{
|
||||
QmiMessageDmsSetUserLockCodeInput *input = NULL;
|
||||
- gchar **split;
|
||||
+ g_auto(GStrv) split = NULL;
|
||||
gchar *old_code;
|
||||
gchar *new_code;
|
||||
|
||||
@@ -2330,7 +2323,6 @@ set_user_lock_code_input_create (const gchar *str)
|
||||
input = NULL;
|
||||
}
|
||||
}
|
||||
- g_strfreev (split);
|
||||
|
||||
return input;
|
||||
}
|
||||
--
|
||||
2.45.2
|
||||
|
@ -1,26 +0,0 @@
|
||||
From b723ac5dbf5d055a614fdb8e2b755c086e47c086 Mon Sep 17 00:00:00 2001
|
||||
From: Lubomir Rintel <lkundrak@v3.sk>
|
||||
Date: Thu, 23 May 2024 10:56:12 +0200
|
||||
Subject: [PATCH 6/9] qmicli-dms: do not leak result on error
|
||||
|
||||
The result is not properly disposed in error handling path, resulting
|
||||
in a potential leak.
|
||||
---
|
||||
src/qmicli/qmicli-dms.c | 1 +
|
||||
1 file changed, 1 insertion(+)
|
||||
|
||||
diff --git a/src/qmicli/qmicli-dms.c b/src/qmicli/qmicli-dms.c
|
||||
index d001656f..afba1e19 100644
|
||||
--- a/src/qmicli/qmicli-dms.c
|
||||
+++ b/src/qmicli/qmicli-dms.c
|
||||
@@ -3136,6 +3136,7 @@ get_stored_image_list_stored_images_ready (QmiClientDms *client,
|
||||
qmi_message_dms_list_stored_images_output_unref (output);
|
||||
g_object_unref (task);
|
||||
operation_shutdown (FALSE);
|
||||
+ get_stored_image_result_free (result);
|
||||
return;
|
||||
}
|
||||
|
||||
--
|
||||
2.45.2
|
||||
|
@ -1,24 +0,0 @@
|
||||
From b68d1760f81377dcf807e969a78671f19af38993 Mon Sep 17 00:00:00 2001
|
||||
From: Lubomir Rintel <lkundrak@v3.sk>
|
||||
Date: Thu, 23 May 2024 10:25:45 +0200
|
||||
Subject: [PATCH 7/9] qmicli-nas: avoid leaking mnc
|
||||
|
||||
---
|
||||
src/qmicli/qmicli-nas.c | 1 +
|
||||
1 file changed, 1 insertion(+)
|
||||
|
||||
diff --git a/src/qmicli/qmicli-nas.c b/src/qmicli/qmicli-nas.c
|
||||
index c51a5b02..7f69bfb9 100644
|
||||
--- a/src/qmicli/qmicli-nas.c
|
||||
+++ b/src/qmicli/qmicli-nas.c
|
||||
@@ -3837,6 +3837,7 @@ get_operator_name_ready (QmiClientNas *client,
|
||||
element->lac1,
|
||||
element->lac2,
|
||||
element->plmn_name_record_identifier);
|
||||
+ g_free(mnc);
|
||||
}
|
||||
}
|
||||
|
||||
--
|
||||
2.45.2
|
||||
|
@ -1,25 +0,0 @@
|
||||
From e7651c90e8d081371486deabd44db2b796a546f1 Mon Sep 17 00:00:00 2001
|
||||
From: Lubomir Rintel <lkundrak@v3.sk>
|
||||
Date: Thu, 23 May 2024 10:45:34 +0200
|
||||
Subject: [PATCH 8/9] qmicli-pdc: avoid leaking file_contents[]
|
||||
|
||||
Release it when not needed any more.
|
||||
---
|
||||
src/qmicli/qmicli-pdc.c | 1 +
|
||||
1 file changed, 1 insertion(+)
|
||||
|
||||
diff --git a/src/qmicli/qmicli-pdc.c b/src/qmicli/qmicli-pdc.c
|
||||
index 8139ef4b..4e7a19c4 100644
|
||||
--- a/src/qmicli/qmicli-pdc.c
|
||||
+++ b/src/qmicli/qmicli-pdc.c
|
||||
@@ -1127,6 +1127,7 @@ load_config_file_from_string (const gchar *str)
|
||||
hash_size = g_checksum_type_get_length (G_CHECKSUM_SHA1);
|
||||
checksum = g_checksum_new (G_CHECKSUM_SHA1);
|
||||
g_checksum_update (checksum, file_contents, file_size);
|
||||
+ g_free (file_contents);
|
||||
|
||||
data = g_slice_new (LoadConfigFileData);
|
||||
data->mapped_file = g_mapped_file_ref (mapped_file);
|
||||
--
|
||||
2.45.2
|
||||
|
@ -1,37 +0,0 @@
|
||||
From dadd1683067e13199a535cca71b5e3bc4029f056 Mon Sep 17 00:00:00 2001
|
||||
From: Lubomir Rintel <lkundrak@v3.sk>
|
||||
Date: Thu, 23 May 2024 10:51:14 +0200
|
||||
Subject: [PATCH 9/9] qmicli-ims: fix a silly argument mixup
|
||||
|
||||
Possibly a cut'n'paste oversight or something.
|
||||
---
|
||||
src/qmicli/qmicli-ims.c | 6 +++---
|
||||
1 file changed, 3 insertions(+), 3 deletions(-)
|
||||
|
||||
diff --git a/src/qmicli/qmicli-ims.c b/src/qmicli/qmicli-ims.c
|
||||
index 880aeec7..b690597a 100644
|
||||
--- a/src/qmicli/qmicli-ims.c
|
||||
+++ b/src/qmicli/qmicli-ims.c
|
||||
@@ -195,16 +195,16 @@ get_services_enabled_ready (QmiClientIms *client,
|
||||
g_print ("[%s] IMS services:\n", qmi_device_get_path_display (ctx->device));
|
||||
|
||||
if (qmi_message_ims_get_ims_services_enabled_setting_output_get_ims_voice_service_enabled (output, &service_voice_enabled, NULL))
|
||||
- g_print ("\t IMS registration enabled: %s\n", service_ims_registration_enabled? "yes" : "no");
|
||||
+ g_print ("\t Voice service enabled: %s\n", service_voice_enabled? "yes" : "no");
|
||||
|
||||
if (qmi_message_ims_get_ims_services_enabled_setting_output_get_ims_video_telephony_service_enabled (output, &service_vt_enabled, NULL))
|
||||
- g_print ("\t Voice service enabled: %s\n", service_voice_enabled? "yes" : "no");
|
||||
+ g_print ("\tVideo Telephony service enabled: %s\n", service_vt_enabled? "yes" : "no");
|
||||
|
||||
if (qmi_message_ims_get_ims_services_enabled_setting_output_get_ims_voice_wifi_service_enabled (output, &service_voice_wifi_enabled, NULL))
|
||||
g_print ("\t Voice WiFi service enabled: %s\n", service_voice_wifi_enabled? "yes" : "no");
|
||||
|
||||
if (qmi_message_ims_get_ims_services_enabled_setting_output_get_ims_registration_service_enabled (output, &service_ims_registration_enabled, NULL))
|
||||
- g_print ("\tVideo Telephony service enabled: %s\n", service_vt_enabled? "yes" : "no");
|
||||
+ g_print ("\t IMS registration enabled: %s\n", service_ims_registration_enabled? "yes" : "no");
|
||||
|
||||
if (qmi_message_ims_get_ims_services_enabled_setting_output_get_ims_ut_service_enabled (output, &service_ut_enabled, NULL))
|
||||
g_print ("\t UE to TAS service enabled: %s\n", service_ut_enabled? "yes" : "no");
|
||||
--
|
||||
2.45.2
|
||||
|
@ -1,34 +0,0 @@
|
||||
From 6662764338d3127924cfefaa9cf1b0cc4f90a189 Mon Sep 17 00:00:00 2001
|
||||
From: Arnaud Ferraris <aferraris@debian.org>
|
||||
Date: Sat, 21 Oct 2023 11:43:09 +0200
|
||||
Subject: [PATCH] libqmi-glib,message: fix 16-bit service on big endian
|
||||
architectures
|
||||
|
||||
The latest release introduces handling of 16-bit service indications.
|
||||
However, only the raw message data is returned from
|
||||
`qmi_message_get_service()`, leading to incorrect values on big-endian
|
||||
architectures. As a consequence, `libqmi` ultimately fails to build as
|
||||
the corresponding test errors out in this case.
|
||||
|
||||
This patch ensures the service indication is correct on all kinds of
|
||||
architectures.
|
||||
---
|
||||
src/libqmi-glib/qmi-message.c | 2 +-
|
||||
1 file changed, 1 insertion(+), 1 deletion(-)
|
||||
|
||||
diff --git a/src/libqmi-glib/qmi-message.c b/src/libqmi-glib/qmi-message.c
|
||||
index 3e31b4b4..1918a456 100644
|
||||
--- a/src/libqmi-glib/qmi-message.c
|
||||
+++ b/src/libqmi-glib/qmi-message.c
|
||||
@@ -226,7 +226,7 @@ qmi_message_get_service (QmiMessage *self)
|
||||
if (MESSAGE_IS_QMUX (self))
|
||||
return (QmiService)((struct full_message *)(self->data))->header.qmux.service;
|
||||
|
||||
- return (QmiService)((struct full_message *)(self->data))->header.qrtr.service;
|
||||
+ return (QmiService)GUINT16_FROM_LE (((struct full_message *)(self->data))->header.qrtr.service);
|
||||
}
|
||||
|
||||
guint8
|
||||
--
|
||||
GitLab
|
||||
|
Loading…
Reference in new issue