cli: remove unneeded EOLs when printing PCOs
E.g. in the key-value output: modem.3gpp.pco.length : 2 modem.3gpp.pco.value[1] : session-id: 1, complete: yes, data: 270180\n modem.3gpp.pco.value[2] : session-id: 2, complete: yes, data: 271480802110030100108106503A3DFA8306503A3DFE\n Or in the human output: ---------------------------------- 3GPP | | pco: 1: (complete) '270180' | 2: (complete) '271480802110030100108106503A3DFA8306503A3DFE' ---------------------------------- 3GPP EPS | ue mode of operation: csps-2
This commit is contained in:
@@ -914,12 +914,12 @@ mmcli_output_pco_list (GList *pco_list)
|
|||||||
pco_data_hex = (pco_data ? mm_utils_bin2hexstr (pco_data, pco_data_size) : NULL);
|
pco_data_hex = (pco_data ? mm_utils_bin2hexstr (pco_data, pco_data_size) : NULL);
|
||||||
|
|
||||||
if (selected_type == MMC_OUTPUT_TYPE_HUMAN)
|
if (selected_type == MMC_OUTPUT_TYPE_HUMAN)
|
||||||
g_ptr_array_add (aux, g_strdup_printf ("%u: (%s) '%s'\n",
|
g_ptr_array_add (aux, g_strdup_printf ("%u: (%s) '%s'",
|
||||||
mm_pco_get_session_id (pco),
|
mm_pco_get_session_id (pco),
|
||||||
mm_pco_is_complete (pco) ? "complete" : "partial",
|
mm_pco_is_complete (pco) ? "complete" : "partial",
|
||||||
pco_data_hex ? pco_data_hex : ""));
|
pco_data_hex ? pco_data_hex : ""));
|
||||||
else
|
else
|
||||||
g_ptr_array_add (aux, g_strdup_printf ("session-id: %u, complete: %s, data: %s\n",
|
g_ptr_array_add (aux, g_strdup_printf ("session-id: %u, complete: %s, data: %s",
|
||||||
mm_pco_get_session_id (pco),
|
mm_pco_get_session_id (pco),
|
||||||
mm_pco_is_complete (pco) ? "yes" : "no",
|
mm_pco_is_complete (pco) ? "yes" : "no",
|
||||||
pco_data_hex ? pco_data_hex : ""));
|
pco_data_hex ? pco_data_hex : ""));
|
||||||
|
Reference in New Issue
Block a user