Task #468 - cockpit-314-1.fc40/scan-results.err
back to task #468download
Error: CPPCHECK_WARNING: cockpit-314-build/cockpit-314/src/bridge/cockpitcgroupsamples.c: information[normalCheckLevelMaxBranches]: Limiting analysis of branches. Use --check-level=exhaustive to analyze all branches. Error: CPPCHECK_WARNING: cockpit-314-build/cockpit-314/src/bridge/cockpitconnect.c: information[normalCheckLevelMaxBranches]: Limiting analysis of branches. Use --check-level=exhaustive to analyze all branches. Error: CPPCHECK_WARNING: cockpit-314-build/cockpit-314/src/bridge/cockpitdisksamples.c: information[normalCheckLevelMaxBranches]: Limiting analysis of branches. Use --check-level=exhaustive to analyze all branches. Error: CPPCHECK_WARNING: cockpit-314-build/cockpit-314/src/bridge/cockpitinternalmetrics.c: information[normalCheckLevelMaxBranches]: Limiting analysis of branches. Use --check-level=exhaustive to analyze all branches. Error: CPPCHECK_WARNING: cockpit-314-build/cockpit-314/src/bridge/cockpitmetrics.c: information[normalCheckLevelMaxBranches]: Limiting analysis of branches. Use --check-level=exhaustive to analyze all branches. Error: CPPCHECK_WARNING: cockpit-314-build/cockpit-314/src/bridge/cockpitpcpmetrics.c: information[normalCheckLevelMaxBranches]: Limiting analysis of branches. Use --check-level=exhaustive to analyze all branches. Error: CPPCHECK_WARNING: cockpit-314-build/cockpit-314/src/bridge/cockpitpeer.c: information[normalCheckLevelMaxBranches]: Limiting analysis of branches. Use --check-level=exhaustive to analyze all branches. Error: GCC_ANALYZER_WARNING (CWE-775): cockpit-314-build/cockpit-314/src/bridge/cockpitpeer.c: scope_hint: In function ‘spawn_setup’ cockpit-314-build/cockpit-314/src/bridge/cockpitpeer.c:858:6: warning[-Wanalyzer-fd-leak]: leak of file descriptor ‘dup2(fd, 0)’ # 856| prctl (PR_SET_PDEATHSIG, SIGHUP); # 857| # 858|-> if (dup2 (fd, 0) < 0 || dup2 (fd, 1) < 0) # 859| { # 860| perror ("couldn't set peer stdin/stout file descriptors"); Error: GCC_ANALYZER_WARNING (CWE-775): cockpit-314-build/cockpit-314/src/bridge/cockpitpeer.c:858:24: warning[-Wanalyzer-fd-leak]: leak of file descriptor ‘dup2(fd, 1)’ # 856| prctl (PR_SET_PDEATHSIG, SIGHUP); # 857| # 858|-> if (dup2 (fd, 0) < 0 || dup2 (fd, 1) < 0) # 859| { # 860| perror ("couldn't set peer stdin/stout file descriptors"); Error: CPPCHECK_WARNING: cockpit-314-build/cockpit-314/src/bridge/cockpitrouter.c: information[normalCheckLevelMaxBranches]: Limiting analysis of branches. Use --check-level=exhaustive to analyze all branches. Error: CPPCHECK_WARNING (CWE-457): cockpit-314-build/cockpit-314/src/bridge/cockpitrouter.c:326: error[legacyUninitvar]: Uninitialized variable: host # 324| { # 325| g_debug ("received init message"); # 326|-> g_assert (host != NULL); # 327| self->init_host = g_strdup (host); # 328| problem = NULL; Error: CPPCHECK_WARNING: cockpit-314-build/cockpit-314/src/common/cockpitauthorize.c: information[normalCheckLevelMaxBranches]: Limiting analysis of branches. Use --check-level=exhaustive to analyze all branches. Error: CPPCHECK_WARNING: cockpit-314-build/cockpit-314/src/common/cockpitbase64.c: information[normalCheckLevelMaxBranches]: Limiting analysis of branches. Use --check-level=exhaustive to analyze all branches. Error: CPPCHECK_WARNING: cockpit-314-build/cockpit-314/src/common/cockpitchannel.c: information[normalCheckLevelMaxBranches]: Limiting analysis of branches. Use --check-level=exhaustive to analyze all branches. Error: CPPCHECK_WARNING: cockpit-314-build/cockpit-314/src/common/cockpitconf.c: information[normalCheckLevelMaxBranches]: Limiting analysis of branches. Use --check-level=exhaustive to analyze all branches. Error: CPPCHECK_WARNING: cockpit-314-build/cockpit-314/src/common/cockpitframe.c: information[normalCheckLevelMaxBranches]: Limiting analysis of branches. Use --check-level=exhaustive to analyze all branches. Error: CPPCHECK_WARNING: cockpit-314-build/cockpit-314/src/common/cockpitjson.c: information[normalCheckLevelMaxBranches]: Limiting analysis of branches. Use --check-level=exhaustive to analyze all branches. Error: CPPCHECK_WARNING: cockpit-314-build/cockpit-314/src/common/cockpitmemfdread.c: information[normalCheckLevelMaxBranches]: Limiting analysis of branches. Use --check-level=exhaustive to analyze all branches. Error: CPPCHECK_WARNING: cockpit-314-build/cockpit-314/src/common/cockpitpipe.c: information[normalCheckLevelMaxBranches]: Limiting analysis of branches. Use --check-level=exhaustive to analyze all branches. Error: GCC_ANALYZER_WARNING (CWE-775): cockpit-314-build/cockpit-314/src/common/cockpitpipe.c: scope_hint: In function ‘spawn_setup’ cockpit-314-build/cockpit-314/src/common/cockpitpipe.c:1279:1: warning[-Wanalyzer-fd-leak]: leak of file descriptor ‘r’ /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. cockpit-314-build/cockpit-314/src/common/cockpitpipe.h:23: included_from: Included from here. cockpit-314-build/cockpit-314/src/common/cockpitpipe.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’ cockpit-314-build/cockpit-314/src/common/cockpitpipe.c:1277:5: note: in expansion of macro ‘g_assert’ # 1277| g_assert (r == 2); /* that should really never fail */ # 1278| } # 1279|-> } # 1280| # 1281| /** Error: CPPCHECK_WARNING: cockpit-314-build/cockpit-314/src/common/cockpitpipetransport.c: information[normalCheckLevelMaxBranches]: Limiting analysis of branches. Use --check-level=exhaustive to analyze all branches. Error: CPPCHECK_WARNING: cockpit-314-build/cockpit-314/src/common/cockpittemplate.c: information[normalCheckLevelMaxBranches]: Limiting analysis of branches. Use --check-level=exhaustive to analyze all branches. Error: CPPCHECK_WARNING: cockpit-314-build/cockpit-314/src/common/cockpittransport.c: information[normalCheckLevelMaxBranches]: Limiting analysis of branches. Use --check-level=exhaustive to analyze all branches. Error: CPPCHECK_WARNING: cockpit-314-build/cockpit-314/src/common/cockpitwebinject.c: information[normalCheckLevelMaxBranches]: Limiting analysis of branches. Use --check-level=exhaustive to analyze all branches. Error: CPPCHECK_WARNING: cockpit-314-build/cockpit-314/src/common/cockpitwebresponse.c: information[normalCheckLevelMaxBranches]: Limiting analysis of branches. Use --check-level=exhaustive to analyze all branches. Error: GCC_ANALYZER_WARNING (CWE-688): cockpit-314-build/cockpit-314/src/common/cockpitwebresponse.c: scope_hint: In function ‘find_extension’ cockpit-314-build/cockpit-314/src/common/cockpitwebresponse.c:1568:9: warning[-Wanalyzer-null-argument]: use of NULL ‘path’ 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. /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. cockpit-314-build/cockpit-314/src/common/cockpitwebresponse.h:23: included_from: Included from here. cockpit-314-build/cockpit-314/src/common/cockpitwebresponse.c:28: included_from: Included from here. cockpit-314-build/cockpit-314/src/common/cockpitwebresponse.c:1662:14: note: in expansion of macro ‘g_strdup’ /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/glib/gmacros.h:1358:7: note: in expansion of macro ‘_GLIB_AUTOPTR_CLEAR_FUNC_NAME’ /usr/include/glib-2.0/glib/gmacros.h:1372:3: note: in expansion of macro ‘_GLIB_DEFINE_AUTOPTR_CLEANUP_FUNCS’ /usr/include/glib-2.0/glib/glib-autocleanups.h:69:1: note: in expansion of macro ‘G_DEFINE_AUTOPTR_CLEANUP_FUNC’ /usr/include/glib-2.0/glib/gmacros.h:1372:3: note: in expansion of macro ‘_GLIB_DEFINE_AUTOPTR_CLEANUP_FUNCS’ /usr/include/glib-2.0/glib/glib-autocleanups.h:69:1: note: in expansion of macro ‘G_DEFINE_AUTOPTR_CLEANUP_FUNC’ /usr/include/glib-2.0/glib/gmacros.h:1372:3: note: in expansion of macro ‘_GLIB_DEFINE_AUTOPTR_CLEANUP_FUNCS’ /usr/include/glib-2.0/glib/glib-autocleanups.h:69:1: note: in expansion of macro ‘G_DEFINE_AUTOPTR_CLEANUP_FUNC’ cockpit-314-build/cockpit-314/src/common/cockpitwebresponse.c: scope_hint: In function ‘find_extension’ /usr/include/glib-2.0/glib/galloca.h:35: included_from: Included from here. /usr/include/string.h:273:14: note: argument 1 of ‘strrchr’ must be non-null # 1566| const gchar *slash; # 1567| # 1568|-> dot = strrchr (path, '.'); # 1569| slash = strrchr (path, '/'); # 1570| Error: CPPCHECK_WARNING: cockpit-314-build/cockpit-314/src/common/cockpitwebserver.c: information[normalCheckLevelMaxBranches]: Limiting analysis of branches. Use --check-level=exhaustive to analyze all branches. Error: GCC_ANALYZER_WARNING (CWE-688): cockpit-314-build/cockpit-314/src/common/cockpitwebserver.c:832:18: warning[-Wanalyzer-null-argument]: use of NULL where non-null expected cockpit-314-build/cockpit-314/src/common/cockpitwebserver.c:825:33: note: in expansion of macro ‘g_strdup’ cockpit-314-build/cockpit-314/src/common/cockpitwebserver.c: scope_hint: In function ‘cockpit_web_request_process’ <built-in>: note: argument 1 of ‘__builtin_strchr’ must be non-null # 830| self->host = host; # 831| # 832|-> gchar *query = strchr (path_copy, '?'); # 833| if (query) # 834| { Error: GCC_ANALYZER_WARNING (CWE-688): cockpit-314-build/cockpit-314/src/common/cockpitwebserver.c: scope_hint: In function ‘cockpit_web_request_process’ cockpit-314-build/cockpit-314/src/common/cockpitwebserver.c:832:18: warning[-Wanalyzer-null-argument]: use of NULL ‘*self.original_path’ where non-null expected /usr/include/glib-2.0/glib.h:52: 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. cockpit-314-build/cockpit-314/src/common/cockpitwebserver.h:23: included_from: Included from here. cockpit-314-build/cockpit-314/src/common/cockpitwebserver.c:22: included_from: Included from here. cockpit-314-build/cockpit-314/src/common/cockpitwebserver.c:941:8: note: in expansion of macro ‘g_str_equal’ /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. cockpit-314-build/cockpit-314/src/common/cockpitwebserver.c:825:33: note: in expansion of macro ‘g_strdup’ cockpit-314-build/cockpit-314/src/common/cockpitwebserver.c: scope_hint: In function ‘cockpit_web_request_process’ <built-in>: note: argument 1 of ‘__builtin_strchr’ must be non-null # 830| self->host = host; # 831| # 832|-> gchar *query = strchr (path_copy, '?'); # 833| if (query) # 834| { Error: CPPCHECK_WARNING: cockpit-314-build/cockpit-314/src/pam-ssh-add/pam-ssh-add.c: information[normalCheckLevelMaxBranches]: Limiting analysis of branches. Use --check-level=exhaustive to analyze all branches. Error: CPPCHECK_WARNING: cockpit-314-build/cockpit-314/src/session/session-utils.c: information[normalCheckLevelMaxBranches]: Limiting analysis of branches. Use --check-level=exhaustive to analyze all branches. Error: GCC_ANALYZER_WARNING (CWE-775): cockpit-314-build/cockpit-314/src/session/session-utils.c: scope_hint: In function ‘scan_btmp’ cockpit-314-build/cockpit-314/src/session/session-utils.c:351:6: warning[-Wanalyzer-fd-leak]: leak of file descriptor ‘open("/var/log/btmp", 524288)’ cockpit-314-build/cockpit-314/src/session/session-utils.h:24: included_from: Included from here. cockpit-314-build/cockpit-314/src/session/session-utils.c:22: included_from: Included from here. # 349| # 350| out: # 351|-> if (fd > -1) # 352| close (fd); # 353| Error: GCC_ANALYZER_WARNING (CWE-775): cockpit-314-build/cockpit-314/src/session/session-utils.c: scope_hint: In function ‘fd_remap’ cockpit-314-build/cockpit-314/src/session/session-utils.c:537:10: warning[-Wanalyzer-fd-leak]: leak of file descriptor ‘dup2(*<unknown>, i)’ # 535| for (int i = 0; i < n_remap_fds; i++) # 536| if (fds[i] != -1) /* no-op */ # 537|-> if (dup2 (fds[i], i) != i) # 538| abort_with_message ("dup2(%d, %d) failed: %m", fds[i], i); # 539| Error: CPPCHECK_WARNING: cockpit-314-build/cockpit-314/src/session/session.c: information[normalCheckLevelMaxBranches]: Limiting analysis of branches. Use --check-level=exhaustive to analyze all branches. Error: CPPCHECK_WARNING: cockpit-314-build/cockpit-314/src/ssh/cockpitsshrelay.c: information[normalCheckLevelMaxBranches]: Limiting analysis of branches. Use --check-level=exhaustive to analyze all branches. Error: CPPCHECK_WARNING: cockpit-314-build/cockpit-314/src/tls/cockpit-certificate-ensure.c: information[normalCheckLevelMaxBranches]: Limiting analysis of branches. Use --check-level=exhaustive to analyze all branches. Error: CPPCHECK_WARNING: cockpit-314-build/cockpit-314/src/tls/connection.c: information[normalCheckLevelMaxBranches]: Limiting analysis of branches. Use --check-level=exhaustive to analyze all branches. Error: CPPCHECK_WARNING: cockpit-314-build/cockpit-314/src/tls/httpredirect.c: information[normalCheckLevelMaxBranches]: Limiting analysis of branches. Use --check-level=exhaustive to analyze all branches. Error: GCC_ANALYZER_WARNING (CWE-775): cockpit-314-build/cockpit-314/src/tls/server.c: scope_hint: In function ‘server_init’ cockpit-314-build/cockpit-314/src/tls/server.c:243:9: warning[-Wanalyzer-fd-leak]: leak of file descriptor ‘server.first_listener’ cockpit-314-build/cockpit-314/src/tls/server.c:24: included_from: Included from here. # 241| err (EXIT_FAILURE, "failed to bind to port %hu", port); # 242| if (listen (server.first_listener, 1024) < 0) # 243|-> err (EXIT_FAILURE, "failed to listen to server port"); # 244| debug (SERVER, "Server ready. Listening on port %hu, fd %i", port, server.first_listener); # 245| } Error: GCC_ANALYZER_WARNING (CWE-775): cockpit-314-build/cockpit-314/src/tls/server.c:248:20: warning[-Wanalyzer-fd-leak]: leak of file descriptor ‘server.first_listener’ # 246| # 247| /* epoll the listening fds */ # 248|-> server.epollfd = epoll_create1 (EPOLL_CLOEXEC); # 249| if (server.epollfd < 0) # 250| err (EXIT_FAILURE, "Failed to create epoll fd"); Error: CPPCHECK_WARNING: cockpit-314-build/cockpit-314/src/tls/wsinstance-factory.c: information[normalCheckLevelMaxBranches]: Limiting analysis of branches. Use --check-level=exhaustive to analyze all branches. Error: CPPCHECK_WARNING: cockpit-314-build/cockpit-314/src/websocket/websocket.c: information[normalCheckLevelMaxBranches]: Limiting analysis of branches. Use --check-level=exhaustive to analyze all branches. Error: CPPCHECK_WARNING: cockpit-314-build/cockpit-314/src/websocket/websocketclient.c: information[normalCheckLevelMaxBranches]: Limiting analysis of branches. Use --check-level=exhaustive to analyze all branches. Error: CPPCHECK_WARNING: cockpit-314-build/cockpit-314/src/websocket/websocketconnection.c: information[normalCheckLevelMaxBranches]: Limiting analysis of branches. Use --check-level=exhaustive to analyze all branches. Error: CPPCHECK_WARNING: cockpit-314-build/cockpit-314/src/websocket/websocketserver.c: information[normalCheckLevelMaxBranches]: Limiting analysis of branches. Use --check-level=exhaustive to analyze all branches. Error: CPPCHECK_WARNING: cockpit-314-build/cockpit-314/src/ws/cockpitauth.c: information[normalCheckLevelMaxBranches]: Limiting analysis of branches. Use --check-level=exhaustive to analyze all branches. Error: GCC_ANALYZER_WARNING (CWE-775): cockpit-314-build/cockpit-314/src/ws/cockpitauth.c: scope_hint: In function ‘session_child_setup’ cockpit-314-build/cockpit-314/src/ws/cockpitauth.c:454:6: warning[-Wanalyzer-fd-leak]: leak of file descriptor ‘dup2(*(ChildData *)data.io, 0)’ # 452| ChildData *child = data; # 453| # 454|-> if (dup2 (child->io, 0) < 0 || dup2 (child->io, 1) < 0) # 455| { # 456| g_printerr ("couldn't set child stdin/stout file descriptors\n"); Error: GCC_ANALYZER_WARNING (CWE-775): cockpit-314-build/cockpit-314/src/ws/cockpitauth.c:454:31: warning[-Wanalyzer-fd-leak]: leak of file descriptor ‘dup2(*(ChildData *)data.io, 1)’ # 452| ChildData *child = data; # 453| # 454|-> if (dup2 (child->io, 0) < 0 || dup2 (child->io, 1) < 0) # 455| { # 456| g_printerr ("couldn't set child stdin/stout file descriptors\n"); Error: CLANG_WARNING: cockpit-314-build/cockpit-314/src/ws/cockpitauth.c:1127:12: warning[unix.Malloc]: Potential leak of memory pointed to by 'argv' # 1125| argv[argc] = NULL; # 1126| # 1127|-> pipe = session_start_process ((const gchar **) argv, (const gchar **)env, capture_stderr); # 1128| } # 1129| else if (unix_path != NULL) Error: CPPCHECK_WARNING: cockpit-314-build/cockpit-314/src/ws/cockpitchannelresponse.c: information[normalCheckLevelMaxBranches]: Limiting analysis of branches. Use --check-level=exhaustive to analyze all branches. Error: CPPCHECK_WARNING: cockpit-314-build/cockpit-314/src/ws/cockpitcreds.c: information[normalCheckLevelMaxBranches]: Limiting analysis of branches. Use --check-level=exhaustive to analyze all branches. Error: CPPCHECK_WARNING: cockpit-314-build/cockpit-314/src/ws/cockpithandlers.c: information[normalCheckLevelMaxBranches]: Limiting analysis of branches. Use --check-level=exhaustive to analyze all branches. Error: CPPCHECK_WARNING: cockpit-314-build/cockpit-314/src/ws/cockpitwebservice.c: information[normalCheckLevelMaxBranches]: Limiting analysis of branches. Use --check-level=exhaustive to analyze all branches.