ModemManager-1.22.0-3.fc40
List of Defects
Error: GCC_ANALYZER_WARNING (CWE-476): [#def1]
ModemManager-1.22.0/cli/mmcli-common.c: scope_hint: In function ‘get_object_lookup_info’
ModemManager-1.22.0/cli/mmcli-common.c:184:24: warning[-Wanalyzer-null-dereference]: dereference of NULL ‘modem_physdev’
/usr/include/glib-2.0/glib/gstring.h:37: included_from: Included from here.
/usr/include/glib-2.0/glib/giochannel.h:36: included_from: Included from here.
/usr/include/glib-2.0/glib.h:56: included_from: Included from here.
/usr/include/glib-2.0/gobject/gbinding.h:30: included_from: Included from here.
/usr/include/glib-2.0/glib-object.h:24: included_from: Included from here.
/usr/include/glib-2.0/gio/gioenums.h:30: included_from: Included from here.
/usr/include/glib-2.0/gio/giotypes.h:30: included_from: Included from here.
/usr/include/glib-2.0/gio/gio.h:28: included_from: Included from here.
ModemManager-1.22.0/redhat-linux-build/libmm-glib/generated/mm-gdbus-modem.h:12: included_from: Included from here.
ModemManager-1.22.0/libmm-glib/mm-manager.h:35: included_from: Included from here.
ModemManager-1.22.0/libmm-glib/libmm-glib.h:35: included_from: Included from here.
ModemManager-1.22.0/cli/mmcli-common.c:25: included_from: Included from here.
ModemManager-1.22.0/cli/mmcli-common.c:153:9: note: in expansion of macro ‘g_str_has_prefix’
ModemManager-1.22.0/cli/mmcli-common.c:182:9: note: in expansion of macro ‘g_str_has_prefix’
ModemManager-1.22.0/cli/mmcli-common.c:182:9: note: in expansion of macro ‘g_str_has_prefix’
/usr/include/glib-2.0/glib.h:64: included_from: Included from here.
ModemManager-1.22.0/cli/mmcli-common.c:183:9: note: in expansion of macro ‘g_debug’
ModemManager-1.22.0/cli/mmcli-common.c:184:26: note: in expansion of macro ‘g_strdup’
ModemManager-1.22.0/cli/mmcli-common.c: scope_hint: In function ‘get_object_lookup_info’
# 182| if (g_str_has_prefix (str, "/")) {
# 183| g_debug ("Assuming '%s' is the %s physdev path", str, object_type);
# 184|-> *modem_physdev = g_strdup (str);
# 185| return;
# 186| }
Error: CLANG_WARNING: [#def2]
ModemManager-1.22.0/cli/mmcli-common.c:184:24: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'modem_physdev')
# 182| if (g_str_has_prefix (str, "/")) {
# 183| g_debug ("Assuming '%s' is the %s physdev path", str, object_type);
# 184|-> *modem_physdev = g_strdup (str);
# 185| return;
# 186| }
Error: GCC_ANALYZER_WARNING (CWE-476): [#def3]
ModemManager-1.22.0/cli/mmcli-modem-3gpp-profile-manager.c: scope_hint: In function ‘get_modem_ready’
ModemManager-1.22.0/cli/mmcli-modem-3gpp-profile-manager.c:325:13: warning[-Wanalyzer-null-dereference]: dereference of NULL ‘error’
# 323| profile = delete_build_input (delete_str, &error);
# 324| if (!profile) {
# 325|-> g_printerr ("Error parsing profile string: '%s'\n", error->message);
# 326| exit (EXIT_FAILURE);
# 327| }
Error: CLANG_WARNING: [#def4]
ModemManager-1.22.0/cli/mmcli-modem-3gpp-profile-manager.c:325:65: warning[core.NullDereference]: Access to field 'message' results in a dereference of a null pointer (loaded from variable 'error')
# 323| profile = delete_build_input (delete_str, &error);
# 324| if (!profile) {
# 325|-> g_printerr ("Error parsing profile string: '%s'\n", error->message);
# 326| exit (EXIT_FAILURE);
# 327| }
Error: CLANG_WARNING: [#def5]
ModemManager-1.22.0/cli/mmcli-modem-3gpp-profile-manager.c:424:65: warning[core.NullDereference]: Access to field 'message' results in a dereference of a null pointer (loaded from variable 'error')
# 422| profile = delete_build_input (delete_str, &error);
# 423| if (!profile) {
# 424|-> g_printerr ("Error parsing profile string: '%s'\n", error->message);
# 425| exit (EXIT_FAILURE);
# 426| }
Error: GCC_ANALYZER_WARNING (CWE-476): [#def6]
ModemManager-1.22.0/cli/mmcli-output.c: scope_hint: In function ‘dump_output_json’
ModemManager-1.22.0/cli/mmcli-output.c:1520:13: warning[-Wanalyzer-null-dereference]: dereference of NULL ‘current_path’
# 1518| escaped = json_strescape (single->value);
# 1519|
# 1520|-> g_print ("\"%s\":\"%s\"", current_path[cur_dlen], escaped ? escaped : "--");
# 1521| g_free (escaped);
# 1522| } else if (item_l->type == VALUE_TYPE_MULTIPLE) {
Error: CLANG_WARNING: [#def7]
ModemManager-1.22.0/cli/mmcli-output.c:1520:39: warning[core.NullDereference]: Array access (from variable 'current_path') results in a null pointer dereference
# 1518| escaped = json_strescape (single->value);
# 1519|
# 1520|-> g_print ("\"%s\":\"%s\"", current_path[cur_dlen], escaped ? escaped : "--");
# 1521| g_free (escaped);
# 1522| } else if (item_l->type == VALUE_TYPE_MULTIPLE) {
Error: GCC_ANALYZER_WARNING (CWE-476): [#def8]
ModemManager-1.22.0/cli/mmcli-output.c:1528:13: warning[-Wanalyzer-null-dereference]: dereference of NULL ‘current_path’
# 1526| n = multiple->values ? g_strv_length (multiple->values) : 0;
# 1527|
# 1528|-> g_print ("\"%s\":[", current_path[cur_dlen]);
# 1529| for (i = 0; i < n; i++) {
# 1530| if (multiple->is_object) {
Error: CLANG_WARNING: [#def9]
ModemManager-1.22.0/cli/mmcli-output.c:1528:34: warning[core.NullDereference]: Array access (from variable 'current_path') results in a null pointer dereference
# 1526| n = multiple->values ? g_strv_length (multiple->values) : 0;
# 1527|
# 1528|-> g_print ("\"%s\":[", current_path[cur_dlen]);
# 1529| for (i = 0; i < n; i++) {
# 1530| if (multiple->is_object) {
Error: CLANG_WARNING: [#def10]
ModemManager-1.22.0/libmm-glib/mm-common-helpers.c:1889:13: warning[unix.Malloc]: Potential leak of memory pointed to by 'opos'
# 1887| a = mm_utils_hex2byte (ipos);
# 1888| if (a < 0) {
# 1889|-> g_set_error (error, MM_CORE_ERROR, MM_CORE_ERROR_INVALID_ARGS,
# 1890| "Hex byte conversion from '%c%c' failed",
# 1891| ipos[0], ipos[1]);
Error: GCC_ANALYZER_WARNING (CWE-688): [#def11]
ModemManager-1.22.0/libmm-glib/mm-location-gps-nmea.c: scope_hint: In function ‘location_gps_nmea_take_trace’
ModemManager-1.22.0/libmm-glib/mm-location-gps-nmea.c:84:9: warning[-Wanalyzer-null-argument]: use of NULL ‘trace’ where non-null expected
/usr/include/glib-2.0/glib/gstring.h:37: included_from: Included from here.
/usr/include/glib-2.0/glib/giochannel.h:36: included_from: Included from here.
/usr/include/glib-2.0/glib.h:56: included_from: Included from here.
ModemManager-1.22.0/libmm-glib/mm-common-helpers.h:25: included_from: Included from here.
ModemManager-1.22.0/libmm-glib/mm-location-gps-nmea.c:27: included_from: Included from here.
ModemManager-1.22.0/libmm-glib/mm-location-gps-nmea.c:134:48: note: in expansion of macro ‘g_strdup’
ModemManager-1.22.0/libmm-glib/mm-location-gps-nmea.c: scope_hint: In function ‘location_gps_nmea_take_trace’
<built-in>: note: argument 1 of ‘__builtin_strchr’ must be non-null
# 82| gchar *trace_type;
# 83|
# 84|-> i = strchr (trace, ',');
# 85| if (!i || i == trace) {
# 86| g_free (trace);
Error: GCC_ANALYZER_WARNING (CWE-476): [#def12]
ModemManager-1.22.0/libqcdm/src/commands.c: scope_hint: In function ‘qcdm_cmd_log_config_new’
ModemManager-1.22.0/libqcdm/src/commands.c:1744:15: warning[-Wanalyzer-possible-null-dereference]: dereference of possibly-NULL ‘cmd’
ModemManager-1.22.0/libqcdm/src/commands.c:23: included_from: Included from here.
ModemManager-1.22.0/libqcdm/src/commands.c:1725:5: note: in expansion of macro ‘qcdm_return_val_if_fail’
ModemManager-1.22.0/libqcdm/src/errors.h:71:11: note: in definition of macro ‘qcdm_return_val_if_fail’
ModemManager-1.22.0/libqcdm/src/commands.c:1726:5: note: in expansion of macro ‘qcdm_return_val_if_fail’
ModemManager-1.22.0/libqcdm/src/commands.c:1741:5: note: in expansion of macro ‘qcdm_return_val_if_fail’
# 1742|
# 1743| cmd = calloc (1, cmdbufsize);
# 1744|-> cmd->code = DIAG_CMD_LOG_CONFIG;
# 1745| cmd->op = htole32 (op);
# 1746| cmd->equipid = htole32 (equip_id);
Error: GCC_ANALYZER_WARNING (CWE-476): [#def13]
ModemManager-1.22.0/libqcdm/src/commands.c: scope_hint: In function ‘log_config_get_set_result.part.0’
ModemManager-1.22.0/libqcdm/src/commands.c:1882:36: warning[-Wanalyzer-possible-null-dereference]: dereference of possibly-NULL ‘items’
ModemManager-1.22.0/libqcdm/src/commands.c:1881:21: note: in expansion of macro ‘LOG_CODE_SET’
# 1880| for (i = 0; i < num_items; i++) {
# 1881| if (LOG_CODE_SET (rsp->u.get_set_items.mask, i))
# 1882|-> items[count++] = (equipid << 12) | (i & 0x0FFF);
# 1883| }
# 1884|
Error: COMPILER_WARNING: [#def14]
ModemManager-1.22.0/libqcdm/src/result.c: scope_hint: In function ‘val_new_string’
ModemManager-1.22.0/libqcdm/src/result.c:76:25: warning[-Wcalloc-transposed-args]: ‘calloc’ sizes specified with ‘sizeof’ in the earlier argument and not in the later argument
# 76 | v = calloc (sizeof (Val), 1);
# | ^~~
ModemManager-1.22.0/libqcdm/src/result.c:76:25: note: earlier argument should specify number of elements, later size of each element
# 74| qcdm_return_val_if_fail (value != NULL, NULL);
# 75|
# 76|-> v = calloc (sizeof (Val), 1);
# 77| if (v == NULL)
# 78| return NULL;
Error: COMPILER_WARNING: [#def15]
ModemManager-1.22.0/libqcdm/src/result.c: scope_hint: In function ‘val_new_u8’
ModemManager-1.22.0/libqcdm/src/result.c:94:25: warning[-Wcalloc-transposed-args]: ‘calloc’ sizes specified with ‘sizeof’ in the earlier argument and not in the later argument
# 94 | v = calloc (sizeof (Val), 1);
# | ^~~
ModemManager-1.22.0/libqcdm/src/result.c:94:25: note: earlier argument should specify number of elements, later size of each element
# 92| qcdm_return_val_if_fail (key[0] != '\0', NULL);
# 93|
# 94|-> v = calloc (sizeof (Val), 1);
# 95| if (v == NULL)
# 96| return NULL;
Error: COMPILER_WARNING: [#def16]
ModemManager-1.22.0/libqcdm/src/result.c: scope_hint: In function ‘val_new_u8_array’
ModemManager-1.22.0/libqcdm/src/result.c:114:25: warning[-Wcalloc-transposed-args]: ‘calloc’ sizes specified with ‘sizeof’ in the earlier argument and not in the later argument
# 114 | v = calloc (sizeof (Val), 1);
# | ^~~
ModemManager-1.22.0/libqcdm/src/result.c:114:25: note: earlier argument should specify number of elements, later size of each element
# 112| qcdm_return_val_if_fail (array_len > 0, NULL);
# 113|
# 114|-> v = calloc (sizeof (Val), 1);
# 115| if (v == NULL)
# 116| return NULL;
Error: COMPILER_WARNING: [#def17]
ModemManager-1.22.0/libqcdm/src/result.c: scope_hint: In function ‘val_new_u32’
ModemManager-1.22.0/libqcdm/src/result.c:139:25: warning[-Wcalloc-transposed-args]: ‘calloc’ sizes specified with ‘sizeof’ in the earlier argument and not in the later argument
# 139 | v = calloc (sizeof (Val), 1);
# | ^~~
ModemManager-1.22.0/libqcdm/src/result.c:139:25: note: earlier argument should specify number of elements, later size of each element
# 137| qcdm_return_val_if_fail (key[0] != '\0', NULL);
# 138|
# 139|-> v = calloc (sizeof (Val), 1);
# 140| if (v == NULL)
# 141| return NULL;
Error: COMPILER_WARNING: [#def18]
ModemManager-1.22.0/libqcdm/src/result.c: scope_hint: In function ‘val_new_u16_array’
ModemManager-1.22.0/libqcdm/src/result.c:160:25: warning[-Wcalloc-transposed-args]: ‘calloc’ sizes specified with ‘sizeof’ in the earlier argument and not in the later argument
# 160 | v = calloc (sizeof (Val), 1);
# | ^~~
ModemManager-1.22.0/libqcdm/src/result.c:160:25: note: earlier argument should specify number of elements, later size of each element
# 158| qcdm_return_val_if_fail (array_len > 0, NULL);
# 159|
# 160|-> v = calloc (sizeof (Val), 1);
# 161| if (v == NULL)
# 162| return NULL;
Error: COMPILER_WARNING: [#def19]
ModemManager-1.22.0/libqcdm/src/result.c: scope_hint: In function ‘qcdm_result_new’
ModemManager-1.22.0/libqcdm/src/result.c:190:25: warning[-Wcalloc-transposed-args]: ‘calloc’ sizes specified with ‘sizeof’ in the earlier argument and not in the later argument
# 190 | r = calloc (sizeof (QcdmResult), 1);
# | ^~~~~~~~~~
ModemManager-1.22.0/libqcdm/src/result.c:190:25: note: earlier argument should specify number of elements, later size of each element
# 188| QcdmResult *r;
# 189|
# 190|-> r = calloc (sizeof (QcdmResult), 1);
# 191| if (r)
# 192| r->refcount = 1;
Error: CLANG_WARNING: [#def20]
ModemManager-1.22.0/libqcdm/tests/test-qcdm-com.c:1526:5: warning[deadcode.DeadStores]: Value stored to 'reply_len' is never read
# 1524|
# 1525| /* Wait for a log packet */
# 1526|-> reply_len = wait_reply (d, buf, sizeof (buf));
# 1527| }
# 1528|
Error: CLANG_WARNING: [#def21]
ModemManager-1.22.0/libqcdm/tests/test-qcdm-com.c:1561:9: warning[deadcode.DeadStores]: Value stored to 'reply_len' is never read
# 1559| /* Wait for a few events */
# 1560| for (i = 0; i < 4; i++)
# 1561|-> reply_len = wait_reply (d, buf, sizeof (buf));
# 1562|
# 1563| /* Turn event reporting off */
Error: CLANG_WARNING: [#def22]
ModemManager-1.22.0/libqcdm/tests/test-qcdm-com.c:1571:5: warning[deadcode.DeadStores]: Value stored to 'reply_len' is never read
# 1569|
# 1570| /* Get a response */
# 1571|-> reply_len = wait_reply (d, buf, sizeof (buf));
# 1572| }
# 1573|
Error: CLANG_WARNING: [#def23]
ModemManager-1.22.0/libqcdm/tests/test-qcdm-com.c:1662:9: warning[deadcode.DeadStores]: Value stored to 'reply_len' is never read
# 1660| /* Wait for a few log packets */
# 1661| for (i = 0; i < 5; i++)
# 1662|-> reply_len = wait_reply (d, buf, sizeof (buf));
# 1663| }
# 1664|
Error: CLANG_WARNING: [#def24]
ModemManager-1.22.0/redhat-linux-build/ModemManager-scan.c:180:16: warning[deadcode.DeadStores]: Although the value stored to 'event_num' is used in the enclosing expression, the value is never actually read from 'event_num'
Error: CLANG_WARNING: [#def25]
ModemManager-1.22.0/redhat-linux-build/ModemManager-scan.c:406:17: warning[core.uninitialized.Branch]: Branch condition evaluates to a garbage value
Error: CLANG_WARNING: [#def26]
ModemManager-1.22.0/redhat-linux-build/libmm-glib-scan.c:528:16: warning[deadcode.DeadStores]: Although the value stored to 'event_num' is used in the enclosing expression, the value is never actually read from 'event_num'
Error: CLANG_WARNING: [#def27]
ModemManager-1.22.0/redhat-linux-build/tmp-introspectu8948n9_/ModemManager-1.0.c:799:27: warning[core.NullDereference]: Access to field 'message' results in a dereference of a null pointer (loaded from variable 'error')
Error: CLANG_WARNING: [#def28]
ModemManager-1.22.0/src/kerneldevice/mm-kernel-device-generic-rules.c:132:10: warning[core.NonNullParamChecker]: Null pointer passed to 1st parameter expecting 'nonnull'
# 130| return FALSE;
# 131|
# 132|-> if (!g_str_equal (operator, "=")) {
# 133| inner_error = g_error_new (MM_CORE_ERROR, MM_CORE_ERROR_FAILED,
# 134| "Invalid rule result operator: '%s'", item);
Error: CLANG_WARNING: [#def29]
ModemManager-1.22.0/src/kerneldevice/mm-kernel-device-generic-rules.c:189:9: warning[core.NonNullParamChecker]: Null pointer passed to 1st parameter expecting 'nonnull'
# 187| return FALSE;
# 188|
# 189|-> if (g_str_equal (operator, "=="))
# 190| rule_match->type = MM_UDEV_RULE_MATCH_TYPE_EQUAL;
# 191| else if (g_str_equal (operator, "!="))
Error: GCC_ANALYZER_WARNING (CWE-476): [#def30]
ModemManager-1.22.0/src/mm-base-sim.c: scope_hint: In function ‘init_load_gid1_ready’
ModemManager-1.22.0/src/mm-base-sim.c:2540:76: warning[-Wanalyzer-null-dereference]: dereference of NULL ‘*(MMBaseSimClass *)MEM[(struct GTypeInstance *)self_21(D)].g_class.load_gid1_finish(self, res, & error)’
ModemManager-1.22.0/src/mm-base-sim.c:2553:1: note: in expansion of macro ‘BYTEARRAY_REPLY_READY_FN’
ModemManager-1.22.0/src/mm-base-sim.c:2553:1: note: in expansion of macro ‘BYTEARRAY_REPLY_READY_FN’
ModemManager-1.22.0/src/mm-base-sim.c:2553:1: note: in expansion of macro ‘BYTEARRAY_REPLY_READY_FN’
ModemManager-1.22.0/src/mm-base-sim.c:2553:1: note: in expansion of macro ‘BYTEARRAY_REPLY_READY_FN’
# 2538| g_autofree gchar *bytearray_str = NULL; \
# 2539| \
# 2540|-> bytearray_str = mm_utils_bin2hexstr (bytearray->data, bytearray->len); \
# 2541| mm_obj_info (self, "loaded %s: %s", DISPLAY, bytearray_str); \
# 2542| } \
Error: GCC_ANALYZER_WARNING (CWE-476): [#def31]
ModemManager-1.22.0/src/mm-base-sim.c: scope_hint: In function ‘init_load_gid2_ready’
ModemManager-1.22.0/src/mm-base-sim.c:2540:76: warning[-Wanalyzer-null-dereference]: dereference of NULL ‘*(MMBaseSimClass *)MEM[(struct GTypeInstance *)self_21(D)].g_class.load_gid2_finish(self, res, & error)’
ModemManager-1.22.0/src/mm-base-sim.c:2552:1: note: in expansion of macro ‘BYTEARRAY_REPLY_READY_FN’
ModemManager-1.22.0/src/mm-base-sim.c:2552:1: note: in expansion of macro ‘BYTEARRAY_REPLY_READY_FN’
ModemManager-1.22.0/src/mm-base-sim.c:2552:1: note: in expansion of macro ‘BYTEARRAY_REPLY_READY_FN’
ModemManager-1.22.0/src/mm-base-sim.c:2552:1: note: in expansion of macro ‘BYTEARRAY_REPLY_READY_FN’
# 2538| g_autofree gchar *bytearray_str = NULL; \
# 2539| \
# 2540|-> bytearray_str = mm_utils_bin2hexstr (bytearray->data, bytearray->len); \
# 2541| mm_obj_info (self, "loaded %s: %s", DISPLAY, bytearray_str); \
# 2542| } \
Error: CLANG_WARNING: [#def32]
ModemManager-1.22.0/src/mm-bearer-mbim.c:753:5: warning[deadcode.DeadStores]: Value stored to 'response' is never read
# 751|
# 752| /* Ignore all errors, just go on */
# 753|-> response = mbim_device_command_finish (device, res, NULL);
# 754|
# 755| /* Keep on */
Error: GCC_ANALYZER_WARNING (CWE-476): [#def33]
ModemManager-1.22.0/src/mm-broadband-modem-qmi.c: scope_hint: In function ‘get_3gpp_access_technology’
ModemManager-1.22.0/src/mm-broadband-modem-qmi.c:3122:29: warning[-Wanalyzer-null-dereference]: dereference of NULL ‘array_used_flags’
/usr/include/glib-2.0/glib.h:33: included_from: Included from here.
ModemManager-1.22.0/src/mm-broadband-modem.h:22: included_from: Included from here.
ModemManager-1.22.0/src/mm-broadband-modem-qmi.h:19: included_from: Included from here.
ModemManager-1.22.0/src/mm-broadband-modem-qmi.c:27: included_from: Included from here.
ModemManager-1.22.0/src/mm-broadband-modem-qmi.c:3169:33: note: in expansion of macro ‘g_array_index’
/usr/include/glib-2.0/glib/gstring.h:37: included_from: Included from here.
/usr/include/glib-2.0/glib/giochannel.h:36: included_from: Included from here.
/usr/include/glib-2.0/glib.h:56: included_from: Included from here.
ModemManager-1.22.0/src/mm-broadband-modem-qmi.c:3105:27: note: in expansion of macro ‘g_strdup’
ModemManager-1.22.0/src/mm-broadband-modem-qmi.c: scope_hint: In function ‘get_3gpp_access_technology’
# 3120| QmiMessageNasNetworkScanOutputRadioAccessTechnologyElement *element;
# 3121|
# 3122|-> if (array_used_flags[i])
# 3123| continue;
# 3124|
Error: GCC_ANALYZER_WARNING (CWE-476): [#def34]
ModemManager-1.22.0/src/mm-charsets.c: scope_hint: In function ‘charset_iconv_from_utf8’
ModemManager-1.22.0/src/mm-charsets.c:694:45: warning[-Wanalyzer-null-dereference]: dereference of NULL ‘settings’
# 692|
# 693| encoded = (guint8 *) g_convert (utf8, -1,
# 694|-> settings->iconv_name, "UTF-8",
# 695| NULL, &bytes_written, &inner_error);
# 696| if (encoded) {
Error: GCC_ANALYZER_WARNING (CWE-476): [#def35]
ModemManager-1.22.0/src/mm-charsets.c: scope_hint: In function ‘charset_iconv_to_utf8’
ModemManager-1.22.0/src/mm-charsets.c:819:31: warning[-Wanalyzer-null-dereference]: dereference of NULL ‘settings’
/usr/lib64/glib-2.0/include/glibconfig.h:9: included_from: Included from here.
/usr/include/glib-2.0/glib/gtypes.h:34: included_from: Included from here.
/usr/include/glib-2.0/glib/galloca.h:34: included_from: Included from here.
/usr/include/glib-2.0/glib.h:32: included_from: Included from here.
ModemManager-1.22.0/libmm-glib/mm-common-helpers.h:25: included_from: Included from here.
ModemManager-1.22.0/libmm-glib/libmm-glib.h:61: included_from: Included from here.
ModemManager-1.22.0/src/mm-charsets.c:25: included_from: Included from here.
/usr/include/glib-2.0/glib/gmacros.h:1243:31: note: in expansion of macro ‘_G_BOOLEAN_EXPR_IMPL’
/usr/include/glib-2.0/glib/gmacros.h:1244:43: note: in expansion of macro ‘_G_BOOLEAN_EXPR’
/usr/include/glib-2.0/glib/gmessages.h:664:9: note: in expansion of macro ‘G_LIKELY’
ModemManager-1.22.0/src/mm-charsets.c:75:5: note: in expansion of macro ‘g_return_val_if_fail’
# 817| utf8 = g_convert ((const gchar *) data, len,
# 818| "UTF-8",
# 819|-> settings->iconv_name,
# 820| NULL, NULL, &inner_error);
# 821| if (utf8)
Error: GCC_ANALYZER_WARNING (CWE-476): [#def36]
ModemManager-1.22.0/src/mm-charsets.c: scope_hint: In function ‘mm_modem_charset_bytearray_to_utf8’
ModemManager-1.22.0/src/mm-charsets.c:883:81: warning[-Wanalyzer-null-dereference]: dereference of NULL ‘0’
/usr/include/glib-2.0/glib/gmacros.h:1243:31: note: in expansion of macro ‘_G_BOOLEAN_EXPR_IMPL’
/usr/include/glib-2.0/glib/gmacros.h:1244:43: note: in expansion of macro ‘_G_BOOLEAN_EXPR’
/usr/include/glib-2.0/glib/gmessages.h:664:9: note: in expansion of macro ‘G_LIKELY’
ModemManager-1.22.0/src/mm-charsets.c:75:5: note: in expansion of macro ‘g_return_val_if_fail’
# 881|
# 882| if (!utf8) {
# 883|-> g_prefix_error (error, "Invalid conversion from %s to UTF-8: ", settings->gsm_name);
# 884| return NULL;
# 885| }
Error: GCC_ANALYZER_WARNING (CWE-476): [#def37]
ModemManager-1.22.0/src/mm-charsets.c:889:75: warning[-Wanalyzer-null-dereference]: dereference of NULL ‘0’
/usr/include/glib-2.0/glib/gmacros.h:1243:31: note: in expansion of macro ‘_G_BOOLEAN_EXPR_IMPL’
/usr/include/glib-2.0/glib/gmacros.h:1244:43: note: in expansion of macro ‘_G_BOOLEAN_EXPR’
/usr/include/glib-2.0/glib/gmessages.h:664:9: note: in expansion of macro ‘G_LIKELY’
ModemManager-1.22.0/src/mm-charsets.c:75:5: note: in expansion of macro ‘g_return_val_if_fail’
/usr/include/glib-2.0/glib/gmacros.h:1243:31: note: in expansion of macro ‘_G_BOOLEAN_EXPR_IMPL’
/usr/include/glib-2.0/glib/gmacros.h:1244:43: note: in expansion of macro ‘_G_BOOLEAN_EXPR’
/usr/include/glib-2.0/glib/gmessages.h:664:9: note: in expansion of macro ‘G_LIKELY’
ModemManager-1.22.0/src/mm-charsets.c:305:5: note: in expansion of macro ‘g_return_val_if_fail’
/usr/include/glib-2.0/glib/gmacros.h:1243:31: note: in expansion of macro ‘_G_BOOLEAN_EXPR_IMPL’
/usr/include/glib-2.0/glib/gmacros.h:1244:43: note: in expansion of macro ‘_G_BOOLEAN_EXPR’
/usr/include/glib-2.0/glib/gmessages.h:664:9: note: in expansion of macro ‘G_LIKELY’
ModemManager-1.22.0/src/mm-charsets.c:306:5: note: in expansion of macro ‘g_return_val_if_fail’
/usr/include/glib-2.0/glib/gmacros.h:1243:31: note: in expansion of macro ‘_G_BOOLEAN_EXPR_IMPL’
/usr/include/glib-2.0/glib/gmacros.h:1244:43: note: in expansion of macro ‘_G_BOOLEAN_EXPR’
/usr/include/glib-2.0/glib/gmessages.h:664:9: note: in expansion of macro ‘G_LIKELY’
ModemManager-1.22.0/src/mm-charsets.c:306:5: note: in expansion of macro ‘g_return_val_if_fail’
# 887| if (!g_utf8_validate (utf8, -1, NULL)) {
# 888| g_set_error (error, MM_CORE_ERROR, MM_CORE_ERROR_FAILED,
# 889|-> "Invalid conversion from %s: invalid UTF-8", settings->gsm_name);
# 890| return NULL;
# 891| }
Error: CLANG_WARNING: [#def38]
ModemManager-1.22.0/src/mm-charsets.c:978:9: warning[deadcode.DeadStores]: Value stored to 'dec' is never read
# 976| }
# 977|
# 978|-> dec = charset_iconv_to_utf8 (enc,
# 979| enc_size,
# 980| &charset_settings[i],
Error: CLANG_WARNING: [#def39]
ModemManager-1.22.0/src/mm-charsets.c:1080:9: warning[deadcode.DeadStores]: Value stored to 'unichar2' is never read
# 1078|
# 1079| single = g_utf8_get_char (walker);
# 1080|-> unichar2 = g_ucs4_to_utf16 (&single, 1, NULL, &unichar2_written, NULL);
# 1081| g_assert (unichar2_written > 0);
# 1082|
Error: GCC_ANALYZER_WARNING (CWE-476): [#def40]
ModemManager-1.22.0/src/mm-error-helpers.c: scope_hint: In function ‘normalize_error_string’
ModemManager-1.22.0/src/mm-error-helpers.c:34:27: warning[-Wanalyzer-null-dereference]: dereference of NULL ‘str’
/usr/include/glib-2.0/glib/gstring.h:37: included_from: Included from here.
/usr/include/glib-2.0/glib/giochannel.h:36: included_from: Included from here.
/usr/include/glib-2.0/glib.h:56: included_from: Included from here.
/usr/include/glib-2.0/gobject/gbinding.h:30: included_from: Included from here.
/usr/include/glib-2.0/glib-object.h:24: included_from: Included from here.
ModemManager-1.22.0/src/mm-error-helpers.h:21: included_from: Included from here.
ModemManager-1.22.0/src/mm-error-helpers.c:18: included_from: Included from here.
ModemManager-1.22.0/src/mm-error-helpers.c:33:11: note: in expansion of macro ‘g_strdup’
ModemManager-1.22.0/src/mm-error-helpers.c: scope_hint: In function ‘normalize_error_string’
# 32| /* Normalize the error code by stripping whitespace and odd characters */
# 33| buf = g_strdup (str);
# 34|-> for (i = 0, j = 0; str[i]; i++) {
# 35| if (isalnum (str[i]))
# 36| buf[j++] = tolower (str[i]);
Error: GCC_ANALYZER_WARNING (CWE-476): [#def41]
ModemManager-1.22.0/src/mm-iface-modem-firmware.c: scope_hint: In function ‘load_update_settings_ready’
ModemManager-1.22.0/src/mm-iface-modem-firmware.c:433:89: warning[-Wanalyzer-null-dereference]: dereference of NULL ‘0’
ModemManager-1.22.0/src/mm-log-object.h:22: included_from: Included from here.
ModemManager-1.22.0/src/mm-iface-modem-firmware.c:22: included_from: Included from here.
ModemManager-1.22.0/src/mm-iface-modem-firmware.c:424:9: note: in expansion of macro ‘mm_obj_dbg’
/usr/include/glib-2.0/gobject/gobject.h:26: included_from: Included from here.
/usr/include/glib-2.0/gobject/gbinding.h:31: included_from: Included from here.
/usr/include/glib-2.0/glib-object.h:24: included_from: Included from here.
ModemManager-1.22.0/libmm-glib/mm-simple-status.h:31: included_from: Included from here.
ModemManager-1.22.0/libmm-glib/libmm-glib.h:65: included_from: Included from here.
ModemManager-1.22.0/src/mm-iface-modem-firmware.c:18: included_from: Included from here.
/usr/include/glib-2.0/gobject/gtype.h:541:66: note: in expansion of macro ‘_G_TYPE_CIT’
ModemManager-1.22.0/src/mm-broadband-modem-qmi.h:24:49: note: in expansion of macro ‘G_TYPE_CHECK_INSTANCE_TYPE’
ModemManager-1.22.0/src/mm-iface-modem-firmware.c:347:9: note: in expansion of macro ‘MM_IS_BROADBAND_MODEM_QMI’
/usr/include/glib-2.0/gobject/gtype.h:541:66: note: in expansion of macro ‘_G_TYPE_CIT’
ModemManager-1.22.0/src/mm-broadband-modem-qmi.h:24:49: note: in expansion of macro ‘G_TYPE_CHECK_INSTANCE_TYPE’
ModemManager-1.22.0/src/mm-iface-modem-firmware.c:347:9: note: in expansion of macro ‘MM_IS_BROADBAND_MODEM_QMI’
# 431| }
# 432|
# 433|-> mm_firmware_update_settings_set_device_ids (update_settings, (const gchar **)ids->pdata);
# 434| }
# 435|
Error: GCC_ANALYZER_WARNING (CWE-476): [#def42]
ModemManager-1.22.0/src/mm-log-object.h:22: included_from: Included from here.
ModemManager-1.22.0/src/plugins/cinterion/mm-broadband-modem-cinterion.c:31: included_from: Included from here.
ModemManager-1.22.0/src/plugins/cinterion/mm-broadband-modem-cinterion.c: scope_hint: In function ‘cinterion_simlocal_unsolicited_handler’
ModemManager-1.22.0/src/mm-log.h:40:37: warning[-Wanalyzer-null-dereference]: dereference of NULL ‘error’
ModemManager-1.22.0/src/plugins/cinterion/mm-broadband-modem-cinterion.c:3295:9: note: in expansion of macro ‘mm_obj_warn’
ModemManager-1.22.0/src/mm-log.h:40:115: note: in definition of macro ‘mm_obj_warn’
ModemManager-1.22.0/src/mm-log.h:40:115: note: in definition of macro ‘mm_obj_warn’
ModemManager-1.22.0/src/plugins/cinterion/mm-broadband-modem-cinterion.c:3295:9: note: in expansion of macro ‘mm_obj_warn’
# 38| #define mm_obj_log(obj, level, ...) _mm_log (obj, MM_LOG_MODULE_NAME, G_STRLOC, G_STRFUNC, level, ## __VA_ARGS__ )
# 39| #define mm_obj_err(obj, ...) _mm_log (obj, MM_LOG_MODULE_NAME, G_STRLOC, G_STRFUNC, MM_LOG_LEVEL_ERR, ## __VA_ARGS__ )
# 40|-> #define mm_obj_warn(obj, ...) _mm_log (obj, MM_LOG_MODULE_NAME, G_STRLOC, G_STRFUNC, MM_LOG_LEVEL_WARN, ## __VA_ARGS__ )
# 41| #define mm_obj_msg(obj, ...) _mm_log (obj, MM_LOG_MODULE_NAME, G_STRLOC, G_STRFUNC, MM_LOG_LEVEL_MSG, ## __VA_ARGS__ )
# 42| #define mm_obj_info(obj, ...) _mm_log (obj, MM_LOG_MODULE_NAME, G_STRLOC, G_STRFUNC, MM_LOG_LEVEL_INFO, ## __VA_ARGS__ )
Error: GCC_ANALYZER_WARNING (CWE-476): [#def43]
ModemManager-1.22.0/src/mm-log-object.h:22: included_from: Included from here.
ModemManager-1.22.0/src/plugins/cinterion/mm-broadband-bearer-cinterion.c:27: included_from: Included from here.
ModemManager-1.22.0/src/plugins/cinterion/mm-broadband-bearer-cinterion.c: scope_hint: In function ‘disconnect_connection_status_ready’
ModemManager-1.22.0/src/mm-log.h:43:37: warning[-Wanalyzer-null-dereference]: dereference of NULL ‘error’
ModemManager-1.22.0/src/plugins/cinterion/mm-broadband-bearer-cinterion.c:594:9: note: in expansion of macro ‘mm_obj_dbg’
ModemManager-1.22.0/src/mm-log.h:43:115: note: in definition of macro ‘mm_obj_dbg’
ModemManager-1.22.0/src/plugins/cinterion/mm-broadband-bearer-cinterion.c:594:9: note: in expansion of macro ‘mm_obj_dbg’
# 41| #define mm_obj_msg(obj, ...) _mm_log (obj, MM_LOG_MODULE_NAME, G_STRLOC, G_STRFUNC, MM_LOG_LEVEL_MSG, ## __VA_ARGS__ )
# 42| #define mm_obj_info(obj, ...) _mm_log (obj, MM_LOG_MODULE_NAME, G_STRLOC, G_STRFUNC, MM_LOG_LEVEL_INFO, ## __VA_ARGS__ )
# 43|-> #define mm_obj_dbg(obj, ...) _mm_log (obj, MM_LOG_MODULE_NAME, G_STRLOC, G_STRFUNC, MM_LOG_LEVEL_DEBUG, ## __VA_ARGS__ )
# 44|
# 45| /* only allow using non-object logging API if explicitly requested
Error: CLANG_WARNING: [#def44]
ModemManager-1.22.0/src/mm-modem-helpers-qmi.c:2106:35: warning[unix.Malloc]: Potential leak of memory pointed to by 'nr5g_operator_id'
# 2104|
# 2105| /* Process 4G data */
# 2106|-> *out_eps_registration_state = lte_eps_registration_state;
# 2107| if (mm_modem_3gpp_registration_state_is_registered (lte_eps_registration_state)) {
# 2108| REG_INFO_SET (lte_tac, 0, lte_cid, lte_operator_id)
Error: CLANG_WARNING: [#def45]
ModemManager-1.22.0/src/mm-modem-helpers-qmi.c:2115:9: warning[unix.Malloc]: Potential leak of memory pointed to by 'lte_operator_id'
# 2113|
# 2114| /* Process 2G/3G data */
# 2115|-> if (mm_modem_3gpp_registration_state_is_registered (wcdma_ps_registration_state)) {
# 2116| *out_ps_registration_state = wcdma_ps_registration_state;
# 2117| *out_act |= MM_MODEM_ACCESS_TECHNOLOGY_UMTS;
Error: CLANG_WARNING: [#def46]
ModemManager-1.22.0/src/mm-modem-helpers-qmi.c:2127:38: warning[unix.Malloc]: Potential leak of memory pointed to by 'gsm_operator_id'
# 2125| }
# 2126| if (mm_modem_3gpp_registration_state_is_registered (wcdma_cs_registration_state)) {
# 2127|-> *out_cs_registration_state = wcdma_cs_registration_state;
# 2128| *out_act |= MM_MODEM_ACCESS_TECHNOLOGY_UMTS;
# 2129| REG_INFO_SET (0, wcdma_lac, wcdma_cid, wcdma_operator_id)
Error: CLANG_WARNING: [#def47]
ModemManager-1.22.0/src/mm-modem-helpers-qmi.c:2130:16: warning[unix.Malloc]: Potential leak of memory pointed to by 'wcdma_operator_id'
# 2128| *out_act |= MM_MODEM_ACCESS_TECHNOLOGY_UMTS;
# 2129| REG_INFO_SET (0, wcdma_lac, wcdma_cid, wcdma_operator_id)
# 2130|-> } else if (mm_modem_3gpp_registration_state_is_registered (gsm_cs_registration_state)) {
# 2131| *out_cs_registration_state = gsm_cs_registration_state;
# 2132| *out_act |= MM_MODEM_ACCESS_TECHNOLOGY_GSM;
Error: GCC_ANALYZER_WARNING (CWE-688): [#def48]
ModemManager-1.22.0/src/mm-modem-helpers.c: scope_hint: In function ‘split_local_address_and_subnet’
ModemManager-1.22.0/src/mm-modem-helpers.c:2317:21: warning[-Wanalyzer-null-argument]: use of NULL ‘separator’ where non-null expected
/usr/lib64/glib-2.0/include/glibconfig.h:9: included_from: Included from here.
/usr/include/glib-2.0/glib/gtypes.h:34: included_from: Included from here.
/usr/include/glib-2.0/glib/galloca.h:34: included_from: Included from here.
/usr/include/glib-2.0/glib.h:32: included_from: Included from here.
ModemManager-1.22.0/src/mm-modem-helpers.c:22: included_from: Included from here.
/usr/include/glib-2.0/glib/gmacros.h:1243:31: note: in expansion of macro ‘_G_BOOLEAN_EXPR_IMPL’
/usr/include/glib-2.0/glib/gmacros.h:1244:43: note: in expansion of macro ‘_G_BOOLEAN_EXPR’
/usr/include/glib-2.0/glib/gtestutils.h:276:49: note: in expansion of macro ‘G_LIKELY’
ModemManager-1.22.0/src/mm-modem-helpers.c:2311:5: note: in expansion of macro ‘g_assert’
/usr/include/glib-2.0/glib/gmacros.h:1243:31: note: in expansion of macro ‘_G_BOOLEAN_EXPR_IMPL’
/usr/include/glib-2.0/glib/gmacros.h:1244:43: note: in expansion of macro ‘_G_BOOLEAN_EXPR’
/usr/include/glib-2.0/glib/gtestutils.h:276:49: note: in expansion of macro ‘G_LIKELY’
ModemManager-1.22.0/src/mm-modem-helpers.c:2312:5: note: in expansion of macro ‘g_assert’
/usr/include/glib-2.0/glib/gmacros.h:1243:31: note: in expansion of macro ‘_G_BOOLEAN_EXPR_IMPL’
/usr/include/glib-2.0/glib/gmacros.h:1244:43: note: in expansion of macro ‘_G_BOOLEAN_EXPR’
/usr/include/glib-2.0/glib/gtestutils.h:276:49: note: in expansion of macro ‘G_LIKELY’
ModemManager-1.22.0/src/mm-modem-helpers.c:2312:5: note: in expansion of macro ‘g_assert’
/usr/include/glib-2.0/glib/gmacros.h:1243:31: note: in expansion of macro ‘_G_BOOLEAN_EXPR_IMPL’
/usr/include/glib-2.0/glib/gmacros.h:1244:43: note: in expansion of macro ‘_G_BOOLEAN_EXPR’
/usr/include/glib-2.0/glib/gtestutils.h:276:49: note: in expansion of macro ‘G_LIKELY’
ModemManager-1.22.0/src/mm-modem-helpers.c:2313:5: note: in expansion of macro ‘g_assert’
/usr/include/glib-2.0/glib/gmacros.h:1243:31: note: in expansion of macro ‘_G_BOOLEAN_EXPR_IMPL’
/usr/include/glib-2.0/glib/gmacros.h:1244:43: note: in expansion of macro ‘_G_BOOLEAN_EXPR’
/usr/include/glib-2.0/glib/gtestutils.h:276:49: note: in expansion of macro ‘G_LIKELY’
ModemManager-1.22.0/src/mm-modem-helpers.c:2313:5: note: in expansion of macro ‘g_assert’
<built-in>: note: argument 1 of ‘__builtin_strchr’ must be non-null
# 2315| separator = str;
# 2316| while (1) {
# 2317|-> separator = strchr (separator, '.');
# 2318| if (separator) {
# 2319| count++;
Error: GCC_ANALYZER_WARNING (CWE-688): [#def49]
ModemManager-1.22.0/src/mm-modem-helpers.c: scope_hint: In function ‘deact_secondary’
ModemManager-1.22.0/src/mm-modem-helpers.c:3605:11: warning[-Wanalyzer-null-argument]: use of NULL ‘str’ where non-null expected
/usr/include/glib-2.0/glib/gmacros.h:1243:31: note: in expansion of macro ‘_G_BOOLEAN_EXPR_IMPL’
/usr/include/glib-2.0/glib/gmacros.h:1245:45: note: in expansion of macro ‘_G_BOOLEAN_EXPR’
/usr/include/glib-2.0/glib/gstrfuncs.h:166:11: note: in expansion of macro ‘G_UNLIKELY’
ModemManager-1.22.0/src/mm-modem-helpers.c:3617:9: note: in expansion of macro ‘g_str_has_prefix’
/usr/include/glib-2.0/glib/gstring.h:37: included_from: Included from here.
/usr/include/glib-2.0/glib/giochannel.h:36: included_from: Included from here.
/usr/include/glib-2.0/glib.h:56: included_from: Included from here.
ModemManager-1.22.0/src/mm-modem-helpers.c:3617:9: note: in expansion of macro ‘g_str_has_prefix’
/usr/include/glib-2.0/glib/gmacros.h:1243:31: note: in expansion of macro ‘_G_BOOLEAN_EXPR_IMPL’
/usr/include/glib-2.0/glib/gmacros.h:1245:45: note: in expansion of macro ‘_G_BOOLEAN_EXPR’
/usr/include/glib-2.0/glib/gstrfuncs.h:166:11: note: in expansion of macro ‘G_UNLIKELY’
ModemManager-1.22.0/src/mm-modem-helpers.c:3619:9: note: in expansion of macro ‘g_str_has_prefix’
/usr/include/glib-2.0/glib/gmacros.h:1243:31: note: in expansion of macro ‘_G_BOOLEAN_EXPR_IMPL’
/usr/include/glib-2.0/glib/gmacros.h:1245:45: note: in expansion of macro ‘_G_BOOLEAN_EXPR’
/usr/include/glib-2.0/glib/gstrfuncs.h:166:11: note: in expansion of macro ‘G_UNLIKELY’
ModemManager-1.22.0/src/mm-modem-helpers.c:3619:9: note: in expansion of macro ‘g_str_has_prefix’
ModemManager-1.22.0/src/mm-modem-helpers.c:3619:9: note: in expansion of macro ‘g_str_has_prefix’
/usr/include/glib-2.0/glib/gmacros.h:1243:31: note: in expansion of macro ‘_G_BOOLEAN_EXPR_IMPL’
/usr/include/glib-2.0/glib/gmacros.h:1245:45: note: in expansion of macro ‘_G_BOOLEAN_EXPR’
/usr/include/glib-2.0/glib/gstrfuncs.h:166:11: note: in expansion of macro ‘G_UNLIKELY’
ModemManager-1.22.0/src/mm-modem-helpers.c:3621:9: note: in expansion of macro ‘g_str_has_prefix’
/usr/include/glib-2.0/glib/gmacros.h:1243:31: note: in expansion of macro ‘_G_BOOLEAN_EXPR_IMPL’
/usr/include/glib-2.0/glib/gmacros.h:1245:45: note: in expansion of macro ‘_G_BOOLEAN_EXPR’
/usr/include/glib-2.0/glib/gstrfuncs.h:166:11: note: in expansion of macro ‘G_UNLIKELY’
ModemManager-1.22.0/src/mm-modem-helpers.c:3621:9: note: in expansion of macro ‘g_str_has_prefix’
ModemManager-1.22.0/src/mm-modem-helpers.c:3621:9: note: in expansion of macro ‘g_str_has_prefix’
/usr/include/glib-2.0/glib/gmacros.h:1243:31: note: in expansion of macro ‘_G_BOOLEAN_EXPR_IMPL’
/usr/include/glib-2.0/glib/gmacros.h:1245:45: note: in expansion of macro ‘_G_BOOLEAN_EXPR’
/usr/include/glib-2.0/glib/gstrfuncs.h:166:11: note: in expansion of macro ‘G_UNLIKELY’
ModemManager-1.22.0/src/mm-modem-helpers.c:3623:9: note: in expansion of macro ‘g_str_has_prefix’
/usr/include/glib-2.0/glib/gmacros.h:1243:31: note: in expansion of macro ‘_G_BOOLEAN_EXPR_IMPL’
/usr/include/glib-2.0/glib/gmacros.h:1245:45: note: in expansion of macro ‘_G_BOOLEAN_EXPR’
/usr/include/glib-2.0/glib/gstrfuncs.h:166:11: note: in expansion of macro ‘G_UNLIKELY’
ModemManager-1.22.0/src/mm-modem-helpers.c:3623:9: note: in expansion of macro ‘g_str_has_prefix’
ModemManager-1.22.0/src/mm-modem-helpers.c:3623:9: note: in expansion of macro ‘g_str_has_prefix’
/usr/include/glib-2.0/glib/gmacros.h:1243:31: note: in expansion of macro ‘_G_BOOLEAN_EXPR_IMPL’
/usr/include/glib-2.0/glib/gmacros.h:1245:45: note: in expansion of macro ‘_G_BOOLEAN_EXPR’
/usr/include/glib-2.0/glib/gstrfuncs.h:166:11: note: in expansion of macro ‘G_UNLIKELY’
ModemManager-1.22.0/src/mm-modem-helpers.c:3625:9: note: in expansion of macro ‘g_str_has_prefix’
/usr/include/glib-2.0/glib/gmacros.h:1243:31: note: in expansion of macro ‘_G_BOOLEAN_EXPR_IMPL’
/usr/include/glib-2.0/glib/gmacros.h:1245:45: note: in expansion of macro ‘_G_BOOLEAN_EXPR’
/usr/include/glib-2.0/glib/gstrfuncs.h:166:11: note: in expansion of macro ‘G_UNLIKELY’
ModemManager-1.22.0/src/mm-modem-helpers.c:3625:9: note: in expansion of macro ‘g_str_has_prefix’
ModemManager-1.22.0/src/mm-modem-helpers.c:3625:9: note: in expansion of macro ‘g_str_has_prefix’
/usr/include/glib-2.0/glib/gmacros.h:1243:31: note: in expansion of macro ‘_G_BOOLEAN_EXPR_IMPL’
/usr/include/glib-2.0/glib/gmacros.h:1245:45: note: in expansion of macro ‘_G_BOOLEAN_EXPR’
/usr/include/glib-2.0/glib/gstrfuncs.h:166:11: note: in expansion of macro ‘G_UNLIKELY’
ModemManager-1.22.0/src/mm-modem-helpers.c:3627:9: note: in expansion of macro ‘g_str_has_prefix’
/usr/include/glib-2.0/glib/gmacros.h:1243:31: note: in expansion of macro ‘_G_BOOLEAN_EXPR_IMPL’
/usr/include/glib-2.0/glib/gmacros.h:1245:45: note: in expansion of macro ‘_G_BOOLEAN_EXPR’
/usr/include/glib-2.0/glib/gstrfuncs.h:166:11: note: in expansion of macro ‘G_UNLIKELY’
ModemManager-1.22.0/src/mm-modem-helpers.c:3627:9: note: in expansion of macro ‘g_str_has_prefix’
ModemManager-1.22.0/src/mm-modem-helpers.c:3627:9: note: in expansion of macro ‘g_str_has_prefix’
/usr/include/glib-2.0/glib/gmacros.h:1243:31: note: in expansion of macro ‘_G_BOOLEAN_EXPR_IMPL’
/usr/include/glib-2.0/glib/gmacros.h:1245:45: note: in expansion of macro ‘_G_BOOLEAN_EXPR’
/usr/include/glib-2.0/glib/gstrfuncs.h:166:11: note: in expansion of macro ‘G_UNLIKELY’
ModemManager-1.22.0/src/mm-modem-helpers.c:3629:9: note: in expansion of macro ‘g_str_has_prefix’
/usr/include/glib-2.0/glib/gmacros.h:1243:31: note: in expansion of macro ‘_G_BOOLEAN_EXPR_IMPL’
/usr/include/glib-2.0/glib/gmacros.h:1245:45: note: in expansion of macro ‘_G_BOOLEAN_EXPR’
/usr/include/glib-2.0/glib/gstrfuncs.h:166:11: note: in expansion of macro ‘G_UNLIKELY’
ModemManager-1.22.0/src/mm-modem-helpers.c:3629:9: note: in expansion of macro ‘g_str_has_prefix’
ModemManager-1.22.0/src/mm-modem-helpers.c:3629:9: note: in expansion of macro ‘g_str_has_prefix’
/usr/include/glib-2.0/glib/gmacros.h:1243:31: note: in expansion of macro ‘_G_BOOLEAN_EXPR_IMPL’
/usr/include/glib-2.0/glib/gmacros.h:1245:45: note: in expansion of macro ‘_G_BOOLEAN_EXPR’
/usr/include/glib-2.0/glib/gstrfuncs.h:166:11: note: in expansion of macro ‘G_UNLIKELY’
ModemManager-1.22.0/src/mm-modem-helpers.c:3631:9: note: in expansion of macro ‘g_str_has_prefix’
/usr/include/glib-2.0/glib/gmacros.h:1243:31: note: in expansion of macro ‘_G_BOOLEAN_EXPR_IMPL’
/usr/include/glib-2.0/glib/gmacros.h:1245:45: note: in expansion of macro ‘_G_BOOLEAN_EXPR’
/usr/include/glib-2.0/glib/gstrfuncs.h:166:11: note: in expansion of macro ‘G_UNLIKELY’
ModemManager-1.22.0/src/mm-modem-helpers.c:3631:9: note: in expansion of macro ‘g_str_has_prefix’
ModemManager-1.22.0/src/mm-modem-helpers.c:3631:9: note: in expansion of macro ‘g_str_has_prefix’
/usr/include/glib-2.0/glib/gmacros.h:1243:31: note: in expansion of macro ‘_G_BOOLEAN_EXPR_IMPL’
/usr/include/glib-2.0/glib/gmacros.h:1245:45: note: in expansion of macro ‘_G_BOOLEAN_EXPR’
/usr/include/glib-2.0/glib/gstrfuncs.h:166:11: note: in expansion of macro ‘G_UNLIKELY’
ModemManager-1.22.0/src/mm-modem-helpers.c:3633:9: note: in expansion of macro ‘g_str_has_prefix’
/usr/include/glib-2.0/glib/gmacros.h:1243:31: note: in expansion of macro ‘_G_BOOLEAN_EXPR_IMPL’
/usr/include/glib-2.0/glib/gmacros.h:1245:45: note: in expansion of macro ‘_G_BOOLEAN_EXPR’
/usr/include/glib-2.0/glib/gstrfuncs.h:166:11: note: in expansion of macro ‘G_UNLIKELY’
ModemManager-1.22.0/src/mm-modem-helpers.c:3633:9: note: in expansion of macro ‘g_str_has_prefix’
<built-in>: note: argument 1 of ‘__builtin_strstr’ must be non-null
# 3603| * +CGEV: ME DEACT <p_cid>, <cid>, <event_type>
# 3604| */
# 3605|-> str = strstr (str, "DEACT") + 5;
# 3606| while (*str == ' ')
# 3607| str++;
Error: GCC_ANALYZER_WARNING (CWE-688): [#def50]
ModemManager-1.22.0/src/mm-modem-helpers.c: scope_hint: In function ‘mm_3gpp_parse_cgev_indication_pdp’
ModemManager-1.22.0/src/mm-modem-helpers.c:3686:33: warning[-Wanalyzer-null-argument]: use of NULL where non-null expected
/usr/include/glib-2.0/glib/gmacros.h:1243:31: note: in expansion of macro ‘_G_BOOLEAN_EXPR_IMPL’
/usr/include/glib-2.0/glib/gmacros.h:1244:43: note: in expansion of macro ‘_G_BOOLEAN_EXPR’
/usr/include/glib-2.0/glib/gtestutils.h:276:49: note: in expansion of macro ‘G_LIKELY’
ModemManager-1.22.0/src/mm-modem-helpers.c:3673:5: note: in expansion of macro ‘g_assert’
/usr/include/glib-2.0/glib/gmacros.h:1243:31: note: in expansion of macro ‘_G_BOOLEAN_EXPR_IMPL’
/usr/include/glib-2.0/glib/gmacros.h:1244:43: note: in expansion of macro ‘_G_BOOLEAN_EXPR’
/usr/include/glib-2.0/glib/gtestutils.h:276:49: note: in expansion of macro ‘G_LIKELY’
ModemManager-1.22.0/src/mm-modem-helpers.c:3683:5: note: in expansion of macro ‘g_assert’
<built-in>: note: argument 1 of ‘__builtin_strlen’ must be non-null
# 3684|
# 3685| str = mm_strip_tag (str, "+CGEV:");
# 3686|-> g_regex_match_full (r, str, strlen (str), 0, 0, &match_info, &inner_error);
# 3687| if (inner_error) {
# 3688| g_propagate_error (error, inner_error);
Error: GCC_ANALYZER_WARNING (CWE-688): [#def51]
ModemManager-1.22.0/src/mm-modem-helpers.c: scope_hint: In function ‘mm_3gpp_parse_cgev_indication_primary’
ModemManager-1.22.0/src/mm-modem-helpers.c:3759:33: warning[-Wanalyzer-null-argument]: use of NULL where non-null expected
<built-in>: note: argument 1 of ‘__builtin_strlen’ must be non-null
# 3757|
# 3758| str = mm_strip_tag (str, "+CGEV:");
# 3759|-> g_regex_match_full (r, str, strlen (str), 0, 0, &match_info, &inner_error);
# 3760| if (inner_error)
# 3761| goto out;
Error: GCC_ANALYZER_WARNING (CWE-688): [#def52]
ModemManager-1.22.0/src/mm-modem-helpers.c: scope_hint: In function ‘mm_3gpp_parse_cgev_indication_secondary’
ModemManager-1.22.0/src/mm-modem-helpers.c:3816:33: warning[-Wanalyzer-null-argument]: use of NULL where non-null expected
<built-in>: note: argument 1 of ‘__builtin_strlen’ must be non-null
# 3814|
# 3815| str = mm_strip_tag (str, "+CGEV:");
# 3816|-> g_regex_match_full (r, str, strlen (str), 0, 0, &match_info, &inner_error);
# 3817| if (inner_error)
# 3818| goto out;
Error: CLANG_WARNING: [#def53]
ModemManager-1.22.0/src/mm-shared-qmi.c:2650:19: warning[core.NullDereference]: Access to field 'data' results in a dereference of a null pointer (loaded from field 'config_list')
# 2648| ConfigInfo *config;
# 2649|
# 2650|-> config = &g_array_index (priv->config_list, ConfigInfo, ctx->config_requested_i);
# 2651| mm_obj_dbg (self, "using requested carrier configuration '%s' (version 0x%08x, size %u bytes)",
# 2652| config->description, config->version, config->total_size);
Error: CLANG_WARNING: [#def54]
ModemManager-1.22.0/src/mm-shared-qmi.c:2704:95: warning[core.NullDereference]: Access to field 'description' results in a dereference of a null pointer (loaded from variable 'requested_config')
# 2702| active_config = (priv->config_active_default ? NULL : &g_array_index (priv->config_list, ConfigInfo, priv->config_active_i));
# 2703| mm_obj_warn (self, "carrier config switching needed: '%s' -> '%s'",
# 2704|-> active_config ? active_config->description : DEFAULT_CONFIG_DESCRIPTION, requested_config->description);
# 2705|
# 2706| input = qmi_message_pdc_set_selected_config_input_new ();
Error: GCC_ANALYZER_WARNING (CWE-476): [#def55]
ModemManager-1.22.0/src/mm-shared-qmi.c: scope_hint: In function ‘get_config_info_indication’
ModemManager-1.22.0/src/mm-shared-qmi.c:3054:23: warning[-Wanalyzer-null-dereference]: dereference of NULL ‘current_config’
# 3052|
# 3053| /* Ignore if already set */
# 3054|-> if (current_config->description)
# 3055| return;
# 3056|
Error: CLANG_WARNING: [#def56]
ModemManager-1.22.0/src/mm-sms-part-cdma.c:585:9: warning[deadcode.DeadStores]: Value stored to 'numbering_plan' is never read
# 583| }
# 584| } else
# 585|-> numbering_plan = 0xFF;
# 586|
# 587| /* Readability of num_fields; will go to third byte (((bit_offset + 8) / 8) == 1) */
Error: CLANG_WARNING: [#def57]
ModemManager-1.22.0/src/plugins/cinterion/mm-broadband-bearer-cinterion.c:594:92: warning[core.NullDereference]: Access to field 'message' results in a dereference of a null pointer (loaded from variable 'error')
# 592| case MM_BEARER_CONNECTION_STATUS_UNKNOWN:
# 593| /* Assume disconnected */
# 594|-> mm_obj_dbg (self, "couldn't get CID %u status, assume disconnected: %s", ctx->cid, error->message);
# 595| g_clear_error (&error);
# 596| break;
Error: CLANG_WARNING: [#def58]
ModemManager-1.22.0/src/plugins/cinterion/mm-broadband-modem-cinterion.c:1656:13: warning[deadcode.DeadStores]: Value stored to 'cmd' is never read
# 1654| g_autofree gchar *cmd = NULL;
# 1655|
# 1656|-> cmd = g_strdup_printf ("+CGCONTRDP=%u", self->priv->initial_eps_bearer_cid);
# 1657| mm_base_modem_at_command (
# 1658| MM_BASE_MODEM (self),
Error: CLANG_WARNING: [#def59]
ModemManager-1.22.0/src/plugins/cinterion/mm-broadband-modem-cinterion.c:3295:74: warning[core.NullDereference]: Access to field 'message' results in a dereference of a null pointer (loaded from variable 'error')
# 3293| response = g_match_info_fetch (match_info, 1);
# 3294| if (!response || !mm_cinterion_get_available_from_simlocal (response, &available, &error)) {
# 3295|-> mm_obj_warn (self, "Could not parse list of available SIMs: %s", error->message);
# 3296| return;
# 3297| }
Error: CLANG_WARNING: [#def60]
ModemManager-1.22.0/src/plugins/huawei/mm-broadband-modem-huawei.c:1203:24: warning[core.NullDereference]: Access to field 'allowed' results in a dereference of a null pointer (loaded from variable 'current')
# 1201|
# 1202| out = g_new (MMModemModeCombination, 1);
# 1203|-> out->allowed = current->allowed;
# 1204| out->preferred = current->preferred;
# 1205| g_task_return_pointer (task, out, g_free);
Error: GCC_ANALYZER_WARNING (CWE-476): [#def61]
ModemManager-1.22.0/src/plugins/huawei/mm-broadband-modem-huawei.c: scope_hint: In function ‘prefmode_load_current_modes_ready’
ModemManager-1.22.0/src/plugins/huawei/mm-broadband-modem-huawei.c:1203:31: warning[-Wanalyzer-null-dereference]: dereference of NULL ‘current’
/usr/include/glib-2.0/glib/glist.h:34: included_from: Included from here.
/usr/include/glib-2.0/glib/ghash.h:36: included_from: Included from here.
/usr/include/glib-2.0/glib.h:52: included_from: Included from here.
ModemManager-1.22.0/libmm-glib/mm-common-helpers.h:25: included_from: Included from here.
ModemManager-1.22.0/libmm-glib/libmm-glib.h:61: included_from: Included from here.
ModemManager-1.22.0/src/plugins/huawei/mm-broadband-modem-huawei.c:32: included_from: Included from here.
/usr/include/glib-2.0/glib/gmem.h:315:57: note: in expansion of macro ‘_G_NEW’
ModemManager-1.22.0/src/plugins/huawei/mm-broadband-modem-huawei.c:1202:15: note: in expansion of macro ‘g_new’
# 1201|
# 1202| out = g_new (MMModemModeCombination, 1);
# 1203|-> out->allowed = current->allowed;
# 1204| out->preferred = current->preferred;
# 1205| g_task_return_pointer (task, out, g_free);
Error: CLANG_WARNING: [#def62]
ModemManager-1.22.0/src/plugins/huawei/mm-broadband-modem-huawei.c:1231:24: warning[core.NullDereference]: Access to field 'allowed' results in a dereference of a null pointer (loaded from variable 'current')
# 1229|
# 1230| out = g_new (MMModemModeCombination, 1);
# 1231|-> out->allowed = current->allowed;
# 1232| out->preferred = current->preferred;
# 1233| g_task_return_pointer (task, out, g_free);
Error: GCC_ANALYZER_WARNING (CWE-476): [#def63]
ModemManager-1.22.0/src/plugins/huawei/mm-broadband-modem-huawei.c: scope_hint: In function ‘syscfg_load_current_modes_ready’
ModemManager-1.22.0/src/plugins/huawei/mm-broadband-modem-huawei.c:1231:31: warning[-Wanalyzer-null-dereference]: dereference of NULL ‘current’
/usr/include/glib-2.0/glib/gmem.h:315:57: note: in expansion of macro ‘_G_NEW’
ModemManager-1.22.0/src/plugins/huawei/mm-broadband-modem-huawei.c:1230:15: note: in expansion of macro ‘g_new’
# 1229|
# 1230| out = g_new (MMModemModeCombination, 1);
# 1231|-> out->allowed = current->allowed;
# 1232| out->preferred = current->preferred;
# 1233| g_task_return_pointer (task, out, g_free);
Error: CLANG_WARNING: [#def64]
ModemManager-1.22.0/src/plugins/huawei/mm-broadband-modem-huawei.c:1258:24: warning[core.NullDereference]: Access to field 'allowed' results in a dereference of a null pointer (loaded from variable 'current')
# 1256|
# 1257| out = g_new (MMModemModeCombination, 1);
# 1258|-> out->allowed = current->allowed;
# 1259| out->preferred = current->preferred;
# 1260| g_task_return_pointer (task, out, g_free);
Error: GCC_ANALYZER_WARNING (CWE-476): [#def65]
ModemManager-1.22.0/src/plugins/huawei/mm-broadband-modem-huawei.c: scope_hint: In function ‘syscfgex_load_current_modes_ready’
ModemManager-1.22.0/src/plugins/huawei/mm-broadband-modem-huawei.c:1258:31: warning[-Wanalyzer-null-dereference]: dereference of NULL ‘current’
/usr/include/glib-2.0/glib/gmem.h:315:57: note: in expansion of macro ‘_G_NEW’
ModemManager-1.22.0/src/plugins/huawei/mm-broadband-modem-huawei.c:1257:15: note: in expansion of macro ‘g_new’
# 1256|
# 1257| out = g_new (MMModemModeCombination, 1);
# 1258|-> out->allowed = current->allowed;
# 1259| out->preferred = current->preferred;
# 1260| g_task_return_pointer (task, out, g_free);
Error: CLANG_WARNING: [#def66]
ModemManager-1.22.0/src/plugins/huawei/mm-broadband-modem-huawei.c:3646:28: warning[core.uninitialized.Branch]: Branch condition evaluates to a garbage value
# 3644| else
# 3645| g_task_return_int (task,
# 3646|-> sw_state ? MM_MODEM_POWER_STATE_ON : MM_MODEM_POWER_STATE_LOW);
# 3647|
# 3648| g_object_unref (task);
Error: GCC_ANALYZER_WARNING (CWE-476): [#def67]
ModemManager-1.22.0/src/plugins/icera/mm-broadband-modem-icera.c: scope_hint: In function ‘load_supported_modes_finish’
ModemManager-1.22.0/src/plugins/icera/mm-broadband-modem-icera.c:175:37: warning[-Wanalyzer-null-dereference]: dereference of NULL ‘interval_separator’
/usr/lib64/glib-2.0/include/glibconfig.h:9: included_from: Included from here.
/usr/include/glib-2.0/glib/gtypes.h:34: included_from: Included from here.
/usr/include/glib-2.0/glib/galloca.h:34: included_from: Included from here.
/usr/include/glib-2.0/glib.h:32: included_from: Included from here.
ModemManager-1.22.0/src/mm-serial-parsers.h:19: included_from: Included from here.
ModemManager-1.22.0/src/plugins/icera/mm-broadband-modem-icera.c:27: included_from: Included from here.
/usr/include/glib-2.0/glib/gmacros.h:1243:31: note: in expansion of macro ‘_G_BOOLEAN_EXPR_IMPL’
/usr/include/glib-2.0/glib/gmacros.h:1244:43: note: in expansion of macro ‘_G_BOOLEAN_EXPR’
/usr/include/glib-2.0/glib/gtestutils.h:276:49: note: in expansion of macro ‘G_LIKELY’
ModemManager-1.22.0/src/plugins/icera/mm-broadband-modem-icera.c:144:5: note: in expansion of macro ‘g_assert’
/usr/include/glib-2.0/glib/gstring.h:37: included_from: Included from here.
/usr/include/glib-2.0/glib/giochannel.h:36: included_from: Included from here.
/usr/include/glib-2.0/glib.h:56: included_from: Included from here.
ModemManager-1.22.0/src/plugins/icera/mm-broadband-modem-icera.c:166:9: note: in expansion of macro ‘g_strstrip’
ModemManager-1.22.0/src/plugins/icera/mm-broadband-modem-icera.c:173:21: note: in expansion of macro ‘g_strdup’
ModemManager-1.22.0/src/plugins/icera/mm-broadband-modem-icera.c: scope_hint: In function ‘load_supported_modes_finish’
# 173| first = g_strdup (split[i]);
# 174| interval_separator = strstr (first, "-");
# 175|-> *(interval_separator++) = '\0';
# 176| last = interval_separator;
# 177|
Error: CLANG_WARNING: [#def68]
ModemManager-1.22.0/src/plugins/novatel/mm-common-novatel.c:56:5: warning[deadcode.DeadStores]: Value stored to 'response' is never read
# 54| probe = g_task_get_source_object (task);
# 55|
# 56|-> response = mm_port_serial_at_command_finish (port, res, &error);
# 57| if (error) {
# 58| if (g_error_matches (error, MM_SERIAL_ERROR, MM_SERIAL_ERROR_RESPONSE_TIMEOUT)) {
Error: CLANG_WARNING: [#def69]
ModemManager-1.22.0/src/plugins/sierra/mm-broadband-modem-sierra.c:730:9: warning[unix.Malloc]: Potential leak of memory pointed to by 'result'
# 728|
# 729| if (error)
# 730|-> g_task_return_error (task, error);
# 731| else
# 732| g_task_return_pointer (task, g_steal_pointer (&result), g_free);
Error: CLANG_WARNING: [#def70]
ModemManager-1.22.0/src/plugins/ublox/mm-modem-helpers-ublox.c:1037:5: warning[deadcode.DeadStores]: Value stored to 'mode' is never read
# 1035| guint i, j;
# 1036|
# 1037|-> mode = supported_modes_per_model (model);
# 1038| bands = g_array_new (FALSE, FALSE, sizeof (MMModemBand));
# 1039|
Error: GCC_ANALYZER_WARNING (CWE-476): [#def71]
ModemManager-1.22.0/src/plugins/ublox/mm-modem-helpers-ublox.c: scope_hint: In function ‘mm_ublox_parse_uact_test’
ModemManager-1.22.0/src/plugins/ublox/mm-modem-helpers-ublox.c:1682:17: warning[-Wanalyzer-null-dereference]: dereference of NULL ‘0’
/usr/lib64/glib-2.0/include/glibconfig.h:9: included_from: Included from here.
/usr/include/glib-2.0/glib/gtypes.h:34: included_from: Included from here.
/usr/include/glib-2.0/glib/galloca.h:34: included_from: Included from here.
/usr/include/glib-2.0/glib.h:32: included_from: Included from here.
ModemManager-1.22.0/src/plugins/ublox/mm-modem-helpers-ublox.c:16: included_from: Included from here.
/usr/include/glib-2.0/glib/gmacros.h:1243:31: note: in expansion of macro ‘_G_BOOLEAN_EXPR_IMPL’
/usr/include/glib-2.0/glib/gmacros.h:1244:43: note: in expansion of macro ‘_G_BOOLEAN_EXPR’
/usr/include/glib-2.0/glib/gtestutils.h:276:49: note: in expansion of macro ‘G_LIKELY’
ModemManager-1.22.0/src/plugins/ublox/mm-modem-helpers-ublox.c:1643:5: note: in expansion of macro ‘g_assert’
/usr/include/glib-2.0/glib/gmacros.h:1243:31: note: in expansion of macro ‘_G_BOOLEAN_EXPR_IMPL’
/usr/include/glib-2.0/glib/gmacros.h:1244:43: note: in expansion of macro ‘_G_BOOLEAN_EXPR’
/usr/include/glib-2.0/glib/gtestutils.h:276:49: note: in expansion of macro ‘G_LIKELY’
ModemManager-1.22.0/src/plugins/ublox/mm-modem-helpers-ublox.c:1651:5: note: in expansion of macro ‘g_assert’
# 1680| bands4g = parse_bands_from_string (bands4g_str, "4G", log_object);
# 1681|
# 1682|-> if (!bands2g->len && !bands3g->len && !bands4g->len) {
# 1683| inner_error = g_error_new (MM_CORE_ERROR, MM_CORE_ERROR_FAILED,
# 1684| "no supported frequencies reported: %s", response);
Error: GCC_ANALYZER_WARNING (CWE-476): [#def72]
ModemManager-1.22.0/src/plugins/ublox/mm-modem-helpers-ublox.c:1682:34: warning[-Wanalyzer-null-dereference]: dereference of NULL ‘0’
/usr/include/glib-2.0/glib/gmacros.h:1243:31: note: in expansion of macro ‘_G_BOOLEAN_EXPR_IMPL’
/usr/include/glib-2.0/glib/gmacros.h:1244:43: note: in expansion of macro ‘_G_BOOLEAN_EXPR’
/usr/include/glib-2.0/glib/gtestutils.h:276:49: note: in expansion of macro ‘G_LIKELY’
ModemManager-1.22.0/src/plugins/ublox/mm-modem-helpers-ublox.c:1643:5: note: in expansion of macro ‘g_assert’
/usr/include/glib-2.0/glib/gmacros.h:1243:31: note: in expansion of macro ‘_G_BOOLEAN_EXPR_IMPL’
/usr/include/glib-2.0/glib/gmacros.h:1244:43: note: in expansion of macro ‘_G_BOOLEAN_EXPR’
/usr/include/glib-2.0/glib/gtestutils.h:276:49: note: in expansion of macro ‘G_LIKELY’
ModemManager-1.22.0/src/plugins/ublox/mm-modem-helpers-ublox.c:1651:5: note: in expansion of macro ‘g_assert’
ModemManager-1.22.0/src/plugins/ublox/mm-modem-helpers-ublox.c: scope_hint: In function ‘mm_ublox_parse_uact_test’
# 1680| bands4g = parse_bands_from_string (bands4g_str, "4G", log_object);
# 1681|
# 1682|-> if (!bands2g->len && !bands3g->len && !bands4g->len) {
# 1683| inner_error = g_error_new (MM_CORE_ERROR, MM_CORE_ERROR_FAILED,
# 1684| "no supported frequencies reported: %s", response);
Error: CLANG_WARNING: [#def73]
ModemManager-1.22.0/src/plugins/ublox/mm-plugin-ublox.c:160:5: warning[deadcode.DeadStores]: Value stored to 'response' is never read
# 158| probe = g_task_get_source_object (task);
# 159|
# 160|-> response = mm_port_serial_at_command_finish (port, res, &error);
# 161| if (error) {
# 162| /* On a timeout error, wait for READY URC */
Error: CLANG_WARNING: [#def74]
ModemManager-1.22.0/src/plugins/wavecom/mm-broadband-modem-wavecom.c:308:9: warning[unix.Malloc]: Potential leak of memory pointed to by 'result'
# 306|
# 307| if (result->allowed == MM_MODEM_MODE_NONE)
# 308|-> g_task_return_new_error (task,
# 309| MM_CORE_ERROR,
# 310| MM_CORE_ERROR_FAILED,
Error: CLANG_WARNING: [#def75]
ModemManager-1.22.0/src/plugins/wavecom/mm-broadband-modem-wavecom.c:375:9: warning[unix.Malloc]: Potential leak of memory pointed to by 'result'
# 373|
# 374| if (result->allowed == MM_MODEM_MODE_NONE)
# 375|-> g_task_return_new_error (task,
# 376| MM_CORE_ERROR,
# 377| MM_CORE_ERROR_FAILED,
Scan Properties
| analyzer-version-clang | 18.1.2 |
| analyzer-version-cppcheck | 2.13.0 |
| analyzer-version-gcc | 14.0.1 |
| analyzer-version-gcc-analyzer | 14.0.1 |
| analyzer-version-shellcheck | 0.9.0 |
| enabled-plugins | clang, cppcheck, gcc, shellcheck |
| exit-code | 0 |
| host | ip-172-16-1-231.us-west-2.compute.internal |
| mock-config | fedora-rawhide-x86_64 |
| project-name | ModemManager-1.22.0-3.fc40 |
| store-results-to | /tmp/tmpkq1k1jpn/ModemManager-1.22.0-3.fc40.tar.xz |
| time-created | 2024-04-13 07:02:37 |
| time-finished | 2024-04-13 07:08:45 |
| tool | csmock |
| tool-args | '/usr/bin/csmock' '-r' 'fedora-rawhide-x86_64' '-t' 'shellcheck,clang,gcc,cppcheck' '-o' '/tmp/tmpkq1k1jpn/ModemManager-1.22.0-3.fc40.tar.xz' '--gcc-analyze' '/tmp/tmpkq1k1jpn/ModemManager-1.22.0-3.fc40.src.rpm' |
| tool-version | csmock-3.5.3-1.el9 |