gnome-software-47.1-1.fc42

List of Findings

Error: GCC_ANALYZER_WARNING (CWE-688): [#def1]
gnome-software-47.1-build/gnome-software-47.1/lib/gs-app-query.c: scope_hint: In function ‘gs_app_query_sanitize_keywords’
gnome-software-47.1-build/gnome-software-47.1/lib/gs-app-query.c:148:21: warning[-Wanalyzer-null-argument]: use of NULL 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.
gnome-software-47.1-build/gnome-software-47.1/lib/gs-app-query.c:47: included_from: Included from here.
gnome-software-47.1-build/gnome-software-47.1/lib/gs-app-query.c:146:42: note: in expansion of macro ‘g_strdup’
gnome-software-47.1-build/gnome-software-47.1/lib/gs-app-query.c:146:42: note: in expansion of macro ‘g_strdup’
gnome-software-47.1-build/gnome-software-47.1/lib/gs-app-query.c: scope_hint: In function ‘gs_app_query_sanitize_keywords’
gnome-software-47.1-build/gnome-software-47.1/lib/gs-app-query.c:147:17: note: in expansion of macro ‘g_strstrip’
<built-in>: note: argument 1 of ‘__builtin_strchr’ must be non-null
#  146|   		g_autofree gchar *term = g_strdup (terms[0]);
#  147|   		g_strstrip (term);
#  148|-> 		if (strchr (term, ' ')) {
#  149|   			g_auto(GStrv) split = g_strsplit (term, " ", -1);
#  150|   			for (guint i = 0; split[i] != NULL; i++) {

Error: GCC_ANALYZER_WARNING (CWE-476): [#def2]
gnome-software-47.1-build/gnome-software-47.1/lib/gs-category.c: scope_hint: In function ‘gs_category_new_for_desktop_data’
gnome-software-47.1-build/gnome-software-47.1/lib/gs-category.c:716:61: warning[-Wanalyzer-null-dereference]: dereference of NULL ‘0’
/usr/include/glib-2.0/glib/gmacros.h:1243:8: note: in definition of macro ‘_G_BOOLEAN_EXPR_IMPL’
/usr/include/glib-2.0/glib/gmacros.h:1250:43: note: in expansion of macro ‘_G_BOOLEAN_EXPR’
/usr/include/glib-2.0/glib/gmessages.h:651:9: note: in expansion of macro ‘G_LIKELY’
gnome-software-47.1-build/gnome-software-47.1/lib/gs-category.c:443:9: note: in expansion of macro ‘g_return_if_fail’
/usr/include/glib-2.0/gobject/gtype.h:1613:40: note: in definition of macro ‘G_DECLARE_FINAL_TYPE’
/usr/include/glib-2.0/gobject/gtype.h:541:66: note: in expansion of macro ‘_G_TYPE_CIT’
/usr/include/glib-2.0/gobject/gtype.h:1614:12: note: in expansion of macro ‘G_TYPE_CHECK_INSTANCE_TYPE’
gnome-software-47.1-build/gnome-software-47.1/lib/gs-category.h:22:1: note: in expansion of macro ‘G_DECLARE_FINAL_TYPE’
/usr/include/glib-2.0/gobject/gtype.h:541:66: note: in expansion of macro ‘_G_TYPE_CIT’
/usr/include/glib-2.0/gobject/gtype.h:1614:12: note: in expansion of macro ‘G_TYPE_CHECK_INSTANCE_TYPE’
gnome-software-47.1-build/gnome-software-47.1/lib/gs-category.h:22:1: note: in expansion of macro ‘G_DECLARE_FINAL_TYPE’
/usr/include/glib-2.0/glib/gmacros.h:1243:8: note: in definition of macro ‘_G_BOOLEAN_EXPR_IMPL’
/usr/include/glib-2.0/glib/gmacros.h:1250:43: note: in expansion of macro ‘_G_BOOLEAN_EXPR’
/usr/include/glib-2.0/glib/gmessages.h:651:9: note: in expansion of macro ‘G_LIKELY’
gnome-software-47.1-build/gnome-software-47.1/lib/gs-category.c:443:9: note: in expansion of macro ‘g_return_if_fail’
/usr/include/glib-2.0/glib/gmacros.h:1243:8: note: in definition of macro ‘_G_BOOLEAN_EXPR_IMPL’
/usr/include/glib-2.0/glib/gmacros.h:1250: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’
gnome-software-47.1-build/gnome-software-47.1/lib/gs-category.c:703:17: note: in expansion of macro ‘g_assert’
/usr/include/glib-2.0/glib/gmacros.h:1249:31: note: in expansion of macro ‘_G_BOOLEAN_EXPR_IMPL’
/usr/include/glib-2.0/glib/gmacros.h:1250: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’
gnome-software-47.1-build/gnome-software-47.1/lib/gs-category.c:703:17: note: in expansion of macro ‘g_assert’
/usr/include/glib-2.0/glib.h:33: included_from: Included from here.
gnome-software-47.1-build/gnome-software-47.1/lib/gs-category.c:710:33: note: in expansion of macro ‘g_ptr_array_index’
/usr/include/glib-2.0/glib/gmacros.h:1249:31: note: in expansion of macro ‘_G_BOOLEAN_EXPR_IMPL’
/usr/include/glib-2.0/glib/gmacros.h:1250: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’
gnome-software-47.1-build/gnome-software-47.1/lib/gs-category.c:301:9: note: in expansion of macro ‘g_return_val_if_fail’
#  714|   			/* add all desktop groups */
#  715|   			desktop_groups = gs_category_get_desktop_groups (child);
#  716|-> 			for (guint j = 0; j < desktop_groups->len; j++) {
#  717|   				const gchar *tmp = g_ptr_array_index (desktop_groups, j);
#  718|   				gs_category_add_desktop_group (subcategory_all, tmp);

Error: CPPCHECK_WARNING (CWE-758): [#def3]
gnome-software-47.1-build/gnome-software-47.1/lib/gs-plugin-types.h:169: error[shiftTooManyBitsSigned]: Shifting signed 32-bit value by 31 bits is undefined behaviour
#  167|   	GS_PLUGIN_REFINE_FLAGS_REQUIRE_DEVELOPER_NAME	= 1 << 29,
#  168|   	GS_PLUGIN_REFINE_FLAGS_REQUIRE_KUDOS		= 1 << 30,
#  169|-> 	GS_PLUGIN_REFINE_FLAGS_REQUIRE_CONTENT_RATING	= 1 << 31,
#  170|   	GS_PLUGIN_REFINE_FLAGS_MASK			= ~0,
#  171|   } GsPluginRefineFlags;

Error: GCC_ANALYZER_WARNING (CWE-457): [#def4]
gnome-software-47.1-build/gnome-software-47.1/plugins/flatpak/gs-plugin-flatpak.c:39: included_from: Included from here.
gnome-software-47.1-build/gnome-software-47.1/lib/gs-profiler.h: scope_hint: In function ‘gs_profiler_tracing_end’
gnome-software-47.1-build/gnome-software-47.1/lib/gs-profiler.h:99:37: warning[-Wanalyzer-use-of-uninitialized-value]: use of uninitialized value ‘*head.description’
/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.
/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.
/usr/include/flatpak/flatpak.h:26: included_from: Included from here.
gnome-software-47.1-build/gnome-software-47.1/plugins/flatpak/gs-plugin-flatpak.c:29: included_from: Included from here.
/usr/include/glib-2.0/glib/gmacros.h:1249:31: note: in expansion of macro ‘_G_BOOLEAN_EXPR_IMPL’
/usr/include/glib-2.0/glib/gmacros.h:1250: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’
gnome-software-47.1-build/gnome-software-47.1/plugins/flatpak/gs-plugin-flatpak.c:70:9: note: in expansion of macro ‘g_assert’
gnome-software-47.1-build/gnome-software-47.1/plugins/flatpak/gs-plugin-flatpak.c:671:9: note: in expansion of macro ‘assert_in_worker’
gnome-software-47.1-build/gnome-software-47.1/lib/gs-profiler.h:123:9: note: in expansion of macro ‘GS_PROFILER_BEGIN_SCOPED_TAKE’
gnome-software-47.1-build/gnome-software-47.1/plugins/flatpak/gs-plugin-flatpak.c:597:9: note: in expansion of macro ‘GS_PROFILER_BEGIN_SCOPED’
gnome-software-47.1-build/gnome-software-47.1/lib/gs-profiler.h:123:9: note: in expansion of macro ‘GS_PROFILER_BEGIN_SCOPED_TAKE’
gnome-software-47.1-build/gnome-software-47.1/plugins/flatpak/gs-plugin-flatpak.c:597:9: note: in expansion of macro ‘GS_PROFILER_BEGIN_SCOPED’
gnome-software-47.1-build/gnome-software-47.1/lib/gs-profiler.h: scope_hint: In function ‘gs_profiler_tracing_end’
#   97|   				"gnome-software",
#   98|   				head->name,
#   99|-> 				head->description);
#  100|   
#  101|   	g_clear_pointer (&head->name, g_free);

Error: CPPCHECK_WARNING (CWE-457): [#def5]
gnome-software-47.1-build/gnome-software-47.1/plugins/dkms/gs-dkms-helper.c:40: error[legacyUninitvar]: Uninitialized variable: key_filename
#   38|   
#   39|   	/* FIXME: use the return code instead of text parsing once the https://github.com/lcp/mokutil/issues/88 is addressed */
#   40|-> 	not_found_output = g_strconcat (key_filename, " not found\n", NULL);
#   41|   	not_enrolled_output = g_strconcat (key_filename, " is not enrolled\n", NULL);
#   42|   	pending_output = g_strconcat (key_filename, " is already in the enrollment request\n", NULL);

Error: CPPCHECK_WARNING (CWE-457): [#def6]
gnome-software-47.1-build/gnome-software-47.1/src/gs-app-context-bar.c:892: error[legacyUninitvar]: Uninitialized variable: dialog
#  890|   		g_assert_not_reached ();
#  891|   
#  892|-> 	adw_dialog_present (dialog, GTK_WIDGET (self));
#  893|   
#  894|   }

Error: COMPILER_WARNING (CWE-477): [#def7]
gnome-software-47.1-build/gnome-software-47.1/src/gs-common.c: scope_hint: In function ‘gs_app_notify_unavailable’
gnome-software-47.1-build/gnome-software-47.1/src/gs-common.c:294:9: warning[-Wdeprecated-declarations]: ‘adw_message_dialog_new’ is deprecated: Use 'adw_alert_dialog_new' instead
/usr/include/libadwaita-1/adwaita.h:62: included_from: Included from here.
gnome-software-47.1-build/gnome-software-47.1/src/gs-common.c:15: included_from: Included from here.
/usr/include/libadwaita-1/adw-message-dialog.h:40:12: note: declared here
#  292|   	}
#  293|   
#  294|-> 	dialog = adw_message_dialog_new (parent,
#  295|   					 title,
#  296|   					 body->str);

Error: COMPILER_WARNING (CWE-477): [#def8]
gnome-software-47.1-build/gnome-software-47.1/src/gs-common.c:297:9: warning[-Wdeprecated-declarations]: ‘adw_message_dialog_set_body_use_markup’ is deprecated: Use 'adw_alert_dialog_set_body_use_markup' instead
/usr/include/libadwaita-1/adw-message-dialog.h:75:10: note: declared here
#  295|   					 title,
#  296|   					 body->str);
#  297|-> 	adw_message_dialog_set_body_use_markup (ADW_MESSAGE_DIALOG (dialog), TRUE);
#  298|   
#  299|   	adw_message_dialog_add_response (ADW_MESSAGE_DIALOG (dialog),

Error: COMPILER_WARNING (CWE-477): [#def9]
gnome-software-47.1-build/gnome-software-47.1/src/gs-common.c:299:9: warning[-Wdeprecated-declarations]: ‘adw_message_dialog_add_response’ is deprecated: Use 'adw_alert_dialog_add_response' instead
/usr/include/libadwaita-1/adw-message-dialog.h:95:6: note: declared here
#  297|   	adw_message_dialog_set_body_use_markup (ADW_MESSAGE_DIALOG (dialog), TRUE);
#  298|   
#  299|-> 	adw_message_dialog_add_response (ADW_MESSAGE_DIALOG (dialog),
#  300|   					 "cancel",  _("_Cancel"));
#  301|   

Error: COMPILER_WARNING (CWE-477): [#def10]
gnome-software-47.1-build/gnome-software-47.1/src/gs-common.c:303:9: warning[-Wdeprecated-declarations]: ‘adw_message_dialog_add_response’ is deprecated: Use 'adw_alert_dialog_add_response' instead
/usr/include/libadwaita-1/adw-message-dialog.h:95:6: note: declared here
#  301|   
#  302|   	/* TRANSLATORS: this is button text to not ask about non-free content again */
#  303|-> 	if (0) adw_message_dialog_add_response (ADW_MESSAGE_DIALOG (dialog), "dont-warn-again",  _("Don’t _Warn Again"));
#  304|   	if (already_enabled) {
#  305|   		adw_message_dialog_add_response (ADW_MESSAGE_DIALOG (dialog),

Error: COMPILER_WARNING (CWE-477): [#def11]
gnome-software-47.1-build/gnome-software-47.1/src/gs-common.c:305:17: warning[-Wdeprecated-declarations]: ‘adw_message_dialog_add_response’ is deprecated: Use 'adw_alert_dialog_add_response' instead
/usr/include/libadwaita-1/adw-message-dialog.h:95:6: note: declared here
#  303|   	if (0) adw_message_dialog_add_response (ADW_MESSAGE_DIALOG (dialog), "dont-warn-again",  _("Don’t _Warn Again"));
#  304|   	if (already_enabled) {
#  305|-> 		adw_message_dialog_add_response (ADW_MESSAGE_DIALOG (dialog),
#  306|   						 /* TRANSLATORS: button text */
#  307|   						 "install", _("_Install"));

Error: COMPILER_WARNING (CWE-477): [#def12]
gnome-software-47.1-build/gnome-software-47.1/src/gs-common.c:310:17: warning[-Wdeprecated-declarations]: ‘adw_message_dialog_add_response’ is deprecated: Use 'adw_alert_dialog_add_response' instead
/usr/include/libadwaita-1/adw-message-dialog.h:95:6: note: declared here
#  308|   
#  309|   	} else {
#  310|-> 		adw_message_dialog_add_response (ADW_MESSAGE_DIALOG (dialog),
#  311|   						 /* TRANSLATORS: button text */
#  312|   						 "install", _("Enable and _Install"));

Error: COMPILER_WARNING (CWE-477): [#def13]
gnome-software-47.1-build/gnome-software-47.1/src/gs-common.c: scope_hint: In function ‘insert_details_widget’
gnome-software-47.1-build/gnome-software-47.1/src/gs-common.c:524:9: warning[-Wdeprecated-declarations]: ‘adw_message_dialog_set_extra_child’ is deprecated: Use 'adw_alert_dialog_set_extra_child' instead
/usr/include/libadwaita-1/adw-message-dialog.h:91:12: note: declared here
#  522|   
#  523|   	box = gtk_box_new (GTK_ORIENTATION_VERTICAL, 0);
#  524|-> 	adw_message_dialog_set_extra_child (ADW_MESSAGE_DIALOG (dialog), box);
#  525|   
#  526|   	label = gtk_label_new (_("Details"));

Error: COMPILER_WARNING (CWE-477): [#def14]
gnome-software-47.1-build/gnome-software-47.1/src/gs-common.c: scope_hint: In function ‘gs_utils_show_error_dialog’
gnome-software-47.1-build/gnome-software-47.1/src/gs-common.c:570:9: warning[-Wdeprecated-declarations]: ‘adw_message_dialog_new’ is deprecated: Use 'adw_alert_dialog_new' instead
/usr/include/libadwaita-1/adw-message-dialog.h:40:12: note: declared here
#  568|   	GtkWidget *dialog;
#  569|   
#  570|-> 	dialog = adw_message_dialog_new (parent, title, msg);
#  571|   	if (details != NULL)
#  572|   		insert_details_widget (ADW_MESSAGE_DIALOG (dialog), details, TRUE);

Error: COMPILER_WARNING (CWE-477): [#def15]
gnome-software-47.1-build/gnome-software-47.1/src/gs-common.c:573:9: warning[-Wdeprecated-declarations]: ‘adw_message_dialog_add_response’ is deprecated: Use 'adw_alert_dialog_add_response' instead
/usr/include/libadwaita-1/adw-message-dialog.h:95:6: note: declared here
#  571|   	if (details != NULL)
#  572|   		insert_details_widget (ADW_MESSAGE_DIALOG (dialog), details, TRUE);
#  573|-> 	adw_message_dialog_add_response (ADW_MESSAGE_DIALOG (dialog),
#  574|   					 /* TRANSLATORS: button text */
#  575|   					 "close", _("_Close"));

Error: COMPILER_WARNING (CWE-477): [#def16]
gnome-software-47.1-build/gnome-software-47.1/src/gs-common.c: scope_hint: In function ‘gs_utils_ask_user_accepts’
gnome-software-47.1-build/gnome-software-47.1/src/gs-common.c:747:9: warning[-Wdeprecated-declarations]: ‘adw_message_dialog_new’ is deprecated: Use 'adw_alert_dialog_new' instead
/usr/include/libadwaita-1/adw-message-dialog.h:40:12: note: declared here
#  745|   	}
#  746|   
#  747|-> 	dialog = adw_message_dialog_new (parent, title, msg);
#  748|   	if (details != NULL)
#  749|   		insert_details_widget (ADW_MESSAGE_DIALOG (dialog), details, FALSE);

Error: COMPILER_WARNING (CWE-477): [#def17]
gnome-software-47.1-build/gnome-software-47.1/src/gs-common.c:750:9: warning[-Wdeprecated-declarations]: ‘adw_message_dialog_add_responses’ is deprecated: Use 'adw_alert_dialog_add_responses' instead
/usr/include/libadwaita-1/adw-message-dialog.h:104:6: note: declared here
#  748|   	if (details != NULL)
#  749|   		insert_details_widget (ADW_MESSAGE_DIALOG (dialog), details, FALSE);
#  750|-> 	adw_message_dialog_add_responses (ADW_MESSAGE_DIALOG (dialog),
#  751|   					  /* TRANSLATORS: button text */
#  752|   					  "cancel", _("_Cancel"),

Error: GCC_ANALYZER_WARNING (CWE-476): [#def18]
gnome-software-47.1-build/gnome-software-47.1/src/gs-description-box.c: scope_hint: In function ‘gs_description_box_update_content’
gnome-software-47.1-build/gnome-software-47.1/src/gs-description-box.c:123:80: warning[-Wanalyzer-null-dereference]: dereference of NULL ‘opened_markup’
#  121|   			if (box->text[start_index] == '<') {
#  122|   				if (box->text[start_index + 1] == '/') {
#  123|-> 					g_autofree gchar *value = opened_markup->data;
#  124|   					opened_markup = g_slist_remove (opened_markup, value);
#  125|   				} else {

Error: CPPCHECK_WARNING (CWE-457): [#def19]
gnome-software-47.1-build/gnome-software-47.1/src/gs-dkms-dialog.c:136: error[legacyUninitvar]: Uninitialized variable: key_kind
#  134|   		g_assert_not_reached ();
#  135|   
#  136|-> 	gs_dkms_enroll_async (key_kind, self->password, self->cancellable, gs_dkms_dialog_enrolled_cb, g_steal_pointer (&task));
#  137|   }
#  138|   

Error: CPPCHECK_WARNING (CWE-457): [#def20]
gnome-software-47.1-build/gnome-software-47.1/src/gs-updates-paused-banner.c:95: error[legacyUninitvar]: Uninitialized variable: title
#   93|   	}
#   94|   
#   95|-> 	adw_banner_set_title (ADW_BANNER (self->banner), title);
#   96|   }
#   97|   

Scan Properties

analyzer-version-clippy1.82.0
analyzer-version-cppcheck2.16.0
analyzer-version-gcc14.2.1
analyzer-version-gcc-analyzer15.0.0
analyzer-version-shellcheck0.10.0
analyzer-version-unicontrol0.0.2
enabled-pluginsclippy, cppcheck, gcc, shellcheck, unicontrol
exit-code0
hostip-172-16-1-44.us-west-2.compute.internal
mock-configfedora-rawhide-gcc-latest-x86_64
project-namegnome-software-47.1-1.fc42
store-results-to/tmp/tmpidfpdy_z/gnome-software-47.1-1.fc42.tar.xz
time-created2024-11-13 00:10:37
time-finished2024-11-13 00:17:53
toolcsmock
tool-args'/usr/bin/csmock' '-r' 'fedora-rawhide-gcc-latest-x86_64' '-t' 'clippy,cppcheck,gcc,unicontrol,shellcheck' '-o' '/tmp/tmpidfpdy_z/gnome-software-47.1-1.fc42.tar.xz' '--gcc-analyze' '--unicontrol-notests' '--unicontrol-bidi-only' '--install=gcc-latest' '--gcc-analyzer-bin=/opt/gcc-latest/bin/gcc' '/tmp/tmpidfpdy_z/gnome-software-47.1-1.fc42.src.rpm'
tool-versioncsmock-3.7.1.20241107.094801.gb3f0f26.pr_192-1.el9