aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorLubomir Rintel <lkundrak@v3.sk>2024-05-26 23:54:50 +0200
committerAleksander Morgado <aleksandermj@chromium.org>2024-05-31 10:46:30 +0000
commit50937f52532a44660df310c075c86130178bf0da (patch)
treed43281f6f6c6ddec0daca76b0ae0c088f26ce213 /src
parent5cdeea43dab0576dbd92ce53aba31c4afcc59db8 (diff)
port-qmi: fix array bound check
There's an off-by-one error.
Diffstat (limited to 'src')
-rw-r--r--src/mm-port-qmi.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/mm-port-qmi.c b/src/mm-port-qmi.c
index f3c64464..38703bc2 100644
--- a/src/mm-port-qmi.c
+++ b/src/mm-port-qmi.c
@@ -1641,7 +1641,7 @@ check_data_format_combination (GTask *task)
/* go on to the next supported combination */
for (++ctx->data_format_combination_i;
- ctx->data_format_combination_i <= (gint)G_N_ELEMENTS (data_format_combinations);
+ ctx->data_format_combination_i < (gint)G_N_ELEMENTS (data_format_combinations);
ctx->data_format_combination_i++) {
const DataFormatCombination *combination;
g_autofree gchar *kernel_data_mode_str = NULL;