Error: COMPILER_WARNING (CWE-195): [#def1] libkcompactdisc-24.08.3-build/libkcompactdisc-24.08.3/src/phonon_interface.cpp: scope_hint: In member function ‘virtual unsigned int KPhononCompactDiscPrivate::trackLength(unsigned int)’ libkcompactdisc-24.08.3-build/libkcompactdisc-24.08.3/src/phonon_interface.cpp:146:75: warning[-Wsign-compare]: comparison of integer expressions of different signedness: ‘int’ and ‘unsigned int’ # 146 | if(!producer() || m_producerWidget->m_mediaController->currentTitle() != track) # | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^~~~~~~~ # 144| unsigned KPhononCompactDiscPrivate::trackLength(unsigned track) # 145| { # 146|-> if(!producer() || m_producerWidget->m_mediaController->currentTitle() != track) # 147| return 0; # 148| Error: COMPILER_WARNING: [#def2] libkcompactdisc-24.08.3-build/libkcompactdisc-24.08.3/src/wmlib/audio/audio_alsa.c:34:9: warning: "_DEFAULT_SOURCE" redefined # 34 | #define _DEFAULT_SOURCE /* stop glibc whining about the previous line */ # | ^~~~~~~~~~~~~~~ /usr/include/bits/libc-header-start.h:33: included_from: Included from here. /usr/include/stdio.h:28: included_from: Included from here. libkcompactdisc-24.08.3-build/libkcompactdisc-24.08.3/src/wmlib/include/wm_config.h:351: included_from: Included from here. libkcompactdisc-24.08.3-build/libkcompactdisc-24.08.3/src/wmlib/audio/audio_alsa.c:27: included_from: Included from here. /usr/include/features.h:246:10: note: this is the location of the previous definition # 246 | # define _DEFAULT_SOURCE 1 # | ^~~~~~~~~~~~~~~ # 32| # 33| #define _BSD_SOURCE /* strdup */ # 34|-> #define _DEFAULT_SOURCE /* stop glibc whining about the previous line */ # 35| # 36| #include <alsa/asoundlib.h> Error: COMPILER_WARNING: [#def3] libkcompactdisc-24.08.3-build/libkcompactdisc-24.08.3/src/wmlib/audio/audio_alsa.c:34:9: warning: ‘_DEFAULT_SOURCE’ redefined /usr/include/bits/libc-header-start.h:33: included_from: Included from here. /usr/include/stdio.h:28: included_from: Included from here. libkcompactdisc-24.08.3-build/libkcompactdisc-24.08.3/src/wmlib/include/wm_config.h:351: included_from: Included from here. libkcompactdisc-24.08.3-build/libkcompactdisc-24.08.3/src/wmlib/audio/audio_alsa.c:27: included_from: Included from here. /usr/include/features.h:246:10: note: this is the location of the previous definition # 32| # 33| #define _BSD_SOURCE /* strdup */ # 34|-> #define _DEFAULT_SOURCE /* stop glibc whining about the previous line */ # 35| # 36| #include <alsa/asoundlib.h> Error: COMPILER_WARNING (CWE-477): [#def4] libkcompactdisc-24.08.3-build/libkcompactdisc-24.08.3/src/wmlib/audio/audio_alsa.c: scope_hint: In function ‘set_swparams’ libkcompactdisc-24.08.3-build/libkcompactdisc-24.08.3/src/wmlib/audio/audio_alsa.c:192:9: warning[-Wdeprecated-declarations]: ‘snd_pcm_sw_params_set_xfer_align’ is deprecated /usr/include/alsa/asoundlib.h:56: included_from: Included from here. libkcompactdisc-24.08.3-build/libkcompactdisc-24.08.3/src/wmlib/audio/audio_alsa.c:36: included_from: Included from here. /usr/include/alsa/pcm.h:1389:5: note: declared here # 190| } # 191| /* align all transfers to 1 sample */ # 192|-> err = snd_pcm_sw_params_set_xfer_align(handle, swparams, 1); # 193| if (err < 0) { # 194| ERRORLOG("Unable to set transfer align for playback: %s\n", snd_strerror(err)); Error: COMPILER_WARNING (CWE-563): [#def5] libkcompactdisc-24.08.3-build/libkcompactdisc-24.08.3/src/wmlib/audio/audio_alsa.c: scope_hint: In function ‘setup_alsa’ libkcompactdisc-24.08.3-build/libkcompactdisc-24.08.3/src/wmlib/audio/audio_alsa.c:330:41: warning[-Wunused-parameter]: unused parameter ‘ctl’ # 330 | setup_alsa(const char *dev, const char *ctl) # | ~~~~~~~~~~~~^~~ # 328| # 329| struct audio_oops* # 330|-> setup_alsa(const char *dev, const char *ctl) # 331| { # 332| static int init_complete = 0; Error: COMPILER_WARNING (CWE-697): [#def6] libkcompactdisc-24.08.3-build/libkcompactdisc-24.08.3/src/wmlib/cdrom.c: scope_hint: In function ‘wm_drive_vendor’ libkcompactdisc-24.08.3-build/libkcompactdisc-24.08.3/src/wmlib/cdrom.c:213:30: warning[-Waddress]: the comparison will always evaluate as ‘true’ for the address of ‘vendor’ will never be NULL # 213 | return pdrive->vendor?pdrive->vendor:""; # | ^ libkcompactdisc-24.08.3-build/libkcompactdisc-24.08.3/src/wmlib/cdrom.c:31: included_from: Included from here. libkcompactdisc-24.08.3-build/libkcompactdisc-24.08.3/src/wmlib/include/wm_struct.h:147:15: note: ‘vendor’ declared here # 147 | char vendor[9]; /* Vendor name */ # | ^~~~~~ # 211| { # 212| struct wm_drive *pdrive = (struct wm_drive *)p; # 213|-> return pdrive->vendor?pdrive->vendor:""; # 214| } # 215| Error: COMPILER_WARNING (CWE-697): [#def7] libkcompactdisc-24.08.3-build/libkcompactdisc-24.08.3/src/wmlib/cdrom.c: scope_hint: In function ‘wm_drive_model’ libkcompactdisc-24.08.3-build/libkcompactdisc-24.08.3/src/wmlib/cdrom.c:219:29: warning[-Waddress]: the comparison will always evaluate as ‘true’ for the address of ‘model’ will never be NULL # 219 | return pdrive->model?pdrive->model:""; # | ^ libkcompactdisc-24.08.3-build/libkcompactdisc-24.08.3/src/wmlib/include/wm_struct.h:148:15: note: ‘model’ declared here # 148 | char model[17]; /* Drive model */ # | ^~~~~ # 217| { # 218| struct wm_drive *pdrive = (struct wm_drive *)p; # 219|-> return pdrive->model?pdrive->model:""; # 220| } # 221| Error: COMPILER_WARNING (CWE-697): [#def8] libkcompactdisc-24.08.3-build/libkcompactdisc-24.08.3/src/wmlib/cdrom.c: scope_hint: In function ‘wm_drive_revision’ libkcompactdisc-24.08.3-build/libkcompactdisc-24.08.3/src/wmlib/cdrom.c:225:32: warning[-Waddress]: the comparison will always evaluate as ‘true’ for the address of ‘revision’ will never be NULL # 225 | return pdrive->revision?pdrive->revision:""; # | ^ libkcompactdisc-24.08.3-build/libkcompactdisc-24.08.3/src/wmlib/include/wm_struct.h:149:15: note: ‘revision’ declared here # 149 | char revision[5]; /* Revision of the drive */ # | ^~~~~~~~ # 223| { # 224| struct wm_drive *pdrive = (struct wm_drive *)p; # 225|-> return pdrive->revision?pdrive->revision:""; # 226| } # 227| Error: COMPILER_WARNING (CWE-697): [#def9] libkcompactdisc-24.08.3-build/libkcompactdisc-24.08.3/src/wmlib/cdrom.c: scope_hint: In function ‘fixup_drive_struct’ libkcompactdisc-24.08.3-build/libkcompactdisc-24.08.3/src/wmlib/cdrom.c:250:39: warning[-Waddress]: the comparison will always evaluate as ‘true’ for the address of ‘revision’ will never be NULL # 250 | ((d->revision != NULL) && strncmp(driver->revision, d->revision, strlen(d->revision)))) # | ^~ libkcompactdisc-24.08.3-build/libkcompactdisc-24.08.3/src/wmlib/include/wm_struct.h:149:15: note: ‘revision’ declared here # 149 | char revision[5]; /* Revision of the drive */ # | ^~~~~~~~ # 248| if((strncmp(driver->vendor, d->vendor, strlen(d->vendor))) || # 249| ((driver->model != NULL) && strncmp(driver->model, d->model, strlen(d->model))) || # 250|-> ((d->revision != NULL) && strncmp(driver->revision, d->revision, strlen(d->revision)))) # 251| continue; # 252| Error: COMPILER_WARNING (CWE-563): [#def10] libkcompactdisc-24.08.3-build/libkcompactdisc-24.08.3/src/wmlib/cdrom.c: scope_hint: In function ‘wm_cd_pause’ libkcompactdisc-24.08.3-build/libkcompactdisc-24.08.3/src/wmlib/cdrom.c:571:20: warning[-Wunused-but-set-variable]: variable ‘paused_pos’ set but not used # 571 | static int paused_pos; # | ^~~~~~~~~~ # 569| { # 570| struct wm_drive *pdrive = (struct wm_drive *)p; # 571|-> static int paused_pos; # 572| int status; # 573| Error: COMPILER_WARNING (CWE-563): [#def11] libkcompactdisc-24.08.3-build/libkcompactdisc-24.08.3/src/wmlib/cdtext.c: scope_hint: In function ‘get_data_from_cdtext_pack’ libkcompactdisc-24.08.3-build/libkcompactdisc-24.08.3/src/wmlib/cdtext.c:159:7: warning[-Wunused-but-set-variable]: variable ‘language_block’ set but not used # 159 | int language_block; # | ^~~~~~~~~~~~~~ # 157| int arr = pack->header_field_id2_tracknumber; # 158| int i; # 159|-> int language_block; # 160| int unicode; # 161| Error: COMPILER_WARNING (CWE-563): [#def12] libkcompactdisc-24.08.3-build/libkcompactdisc-24.08.3/src/wmlib/cdtext.c: scope_hint: In function ‘get_glob_cdtext’ libkcompactdisc-24.08.3-build/libkcompactdisc-24.08.3/src/wmlib/cdtext.c:221:42: warning[-Wunused-but-set-variable]: variable ‘pack_previous’ set but not used # 221 | struct cdtext_pack_data_header *pack, *pack_previous; # | ^~~~~~~~~~~~~ # 219| int ret; # 220| int i; # 221|-> struct cdtext_pack_data_header *pack, *pack_previous; # 222| cdtext_string *p_componente; # 223| struct cdtext_info_block *lp_block; Error: COMPILER_WARNING (CWE-563): [#def13] libkcompactdisc-24.08.3-build/libkcompactdisc-24.08.3/src/wmlib/plat_linux.c: scope_hint: In function ‘gen_init’ libkcompactdisc-24.08.3-build/libkcompactdisc-24.08.3/src/wmlib/plat_linux.c:108:31: warning[-Wunused-parameter]: unused parameter ‘d’ # 108 | int gen_init(struct wm_drive *d) # | ~~~~~~~~~~~~~~~~~^ # 106| * # 107| *-------------------------------------------------------*/ # 108|-> int gen_init(struct wm_drive *d) # 109| { # 110| return 0; Error: COMPILER_WARNING (CWE-563): [#def14] libkcompactdisc-24.08.3-build/libkcompactdisc-24.08.3/src/wmlib/plat_linux.c: scope_hint: In function ‘gen_cdda_init’ libkcompactdisc-24.08.3-build/libkcompactdisc-24.08.3/src/wmlib/plat_linux.c:638:36: warning[-Wunused-parameter]: unused parameter ‘d’ # 638 | int gen_cdda_init(struct wm_drive *d) # | ~~~~~~~~~~~~~~~~~^ # 636| #endif # 637| # 638|-> int gen_cdda_init(struct wm_drive *d) # 639| { # 640| return 0; Error: COMPILER_WARNING: [#def15] libkcompactdisc-24.08.3-build/libkcompactdisc-24.08.3/src/wmlib/scsi.c: scope_hint: In function ‘sendscsi’ libkcompactdisc-24.08.3-build/libkcompactdisc-24.08.3/src/wmlib/scsi.c:123:24: warning[-Wimplicit-fallthrough=]: this statement may fall through # 123 | cdblen = 12; # | ~~~~~~~^~~~ libkcompactdisc-24.08.3-build/libkcompactdisc-24.08.3/src/wmlib/scsi.c:125:9: note: here # 125 | case 1: # | ^~~~ # 121| cdb[10] = a10; # 122| cdb[11] = a11; # 123|-> cdblen = 12; # 124| # 125| case 1: Error: GCC_ANALYZER_WARNING (CWE-688): [#def16] libkcompactdisc-24.08.3-build/libkcompactdisc-24.08.3/src/wmlib/wm_helpers.c: scope_hint: In function ‘wm_libver_number’ libkcompactdisc-24.08.3-build/libkcompactdisc-24.08.3/src/wmlib/wm_helpers.c:66:9: warning[-Wanalyzer-possible-null-argument]: use of possibly-NULL ‘s’ where non-null expected libkcompactdisc-24.08.3-build/libkcompactdisc-24.08.3/src/wmlib/wm_helpers.c: scope_hint: In function ‘wm_libver_number’ libkcompactdisc-24.08.3-build/libkcompactdisc-24.08.3/src/wmlib/wm_helpers.c: scope_hint: In function ‘wm_libver_number’ <built-in>: note: argument 1 of ‘__builtin_sprintf’ must be non-null # 64| s = malloc(10); # 65| /* this is not used very often, so don't care about speed...*/ # 66|-> sprintf(s, "%d.%d.%d", wm_libver_major(), wm_libver_minor(), wm_libver_pl()); # 67| return s; # 68| } /* wm_libver_number() */ Error: GCC_ANALYZER_WARNING (CWE-457): [#def17] libkcompactdisc-24.08.3-build/libkcompactdisc-24.08.3/src/wmlib/wm_helpers.c: scope_hint: In function ‘wm_strmcpy’ libkcompactdisc-24.08.3-build/libkcompactdisc-24.08.3/src/wmlib/wm_helpers.c:123:9: warning[-Wanalyzer-use-of-uninitialized-value]: use of uninitialized value ‘s’ libkcompactdisc-24.08.3-build/libkcompactdisc-24.08.3/src/wmlib/wm_helpers.c: scope_hint: In function ‘wm_strmcpy’ libkcompactdisc-24.08.3-build/libkcompactdisc-24.08.3/src/wmlib/wm_helpers.c: scope_hint: In function ‘wm_strmcpy’ # 121| # 122| wm_lib_message(WM_MSG_CLASS_MISC | WM_MSG_LEVEL_DEBUG, "wm_strmcpy finally copying (%p, '%s')\n", *t, s); # 123|-> strncpy(*t, s, strlen(s)); # 124| } /* wm_strmcpy() */ # 125| Error: COMPILER_WARNING: [#def18] libkcompactdisc-24.08.3-build/libkcompactdisc-24.08.3/src/wmlib/wm_helpers.c: scope_hint: In function ‘wm_strmcpy’ libkcompactdisc-24.08.3-build/libkcompactdisc-24.08.3/src/wmlib/wm_helpers.c:123:9: warning[-Wstringop-truncation]: ‘strncpy’ output truncated before terminating nul copying as many bytes from a string as its length # 123 | strncpy(*t, s, strlen(s)); # | ^ libkcompactdisc-24.08.3-build/libkcompactdisc-24.08.3/src/wmlib/wm_helpers.c:123:9: note: length computed here # 123 | strncpy(*t, s, strlen(s)); # | ^~~~~~~~~~~~~~~~~~~~~~~~~ # 121| # 122| wm_lib_message(WM_MSG_CLASS_MISC | WM_MSG_LEVEL_DEBUG, "wm_strmcpy finally copying (%p, '%s')\n", *t, s); # 123|-> strncpy(*t, s, strlen(s)); # 124| } /* wm_strmcpy() */ # 125| Error: GCC_ANALYZER_WARNING (CWE-401): [#def19] libkcompactdisc-24.08.3-build/libkcompactdisc-24.08.3/src/wmlib/wm_helpers.c: scope_hint: In function ‘wm_strmcat’ libkcompactdisc-24.08.3-build/libkcompactdisc-24.08.3/src/wmlib/wm_helpers.c:140:20: warning[-Wanalyzer-malloc-leak]: leak of ‘s’ libkcompactdisc-24.08.3-build/libkcompactdisc-24.08.3/src/wmlib/wm_helpers.c: scope_hint: In function ‘wm_strmcat’ libkcompactdisc-24.08.3-build/libkcompactdisc-24.08.3/src/wmlib/wm_helpers.c: scope_hint: In function ‘wm_strmcat’ # 138| { # 139| len += strlen(*t); # 140|-> *t = realloc(*t, len); # 141| if (*t == NULL) # 142| { Error: GCC_ANALYZER_WARNING (CWE-401): [#def20] libkcompactdisc-24.08.3-build/libkcompactdisc-24.08.3/src/wmlib/wm_helpers.c:204:31: warning[-Wanalyzer-malloc-leak]: leak of ‘s’ libkcompactdisc-24.08.3-build/libkcompactdisc-24.08.3/src/wmlib/wm_helpers.c: scope_hint: In function ‘wm_strmcat’ libkcompactdisc-24.08.3-build/libkcompactdisc-24.08.3/src/wmlib/wm_helpers.c: scope_hint: In function ‘wm_strmcat’ # 202| unsigned int l, c, vl, vc; # 203| /* verbosity level */ # 204|-> vl = wm_lib_verbosity & WM_MSG_LEVEL_ALL; # 205| /* allowed classes */ # 206| vc = wm_lib_verbosity & WM_MSG_CLASS_ALL; Error: GCC_ANALYZER_WARNING (CWE-401): [#def21] libkcompactdisc-24.08.3-build/libkcompactdisc-24.08.3/src/wmlib/wm_helpers.c:204:31: warning[-Wanalyzer-malloc-leak]: leak of ‘wm_libver_number()’ libkcompactdisc-24.08.3-build/libkcompactdisc-24.08.3/src/wmlib/wm_helpers.c: scope_hint: In function ‘wm_strmcat’ libkcompactdisc-24.08.3-build/libkcompactdisc-24.08.3/src/wmlib/wm_helpers.c: scope_hint: In function ‘wm_strmcat’ # 202| unsigned int l, c, vl, vc; # 203| /* verbosity level */ # 204|-> vl = wm_lib_verbosity & WM_MSG_LEVEL_ALL; # 205| /* allowed classes */ # 206| vc = wm_lib_verbosity & WM_MSG_CLASS_ALL;
analyzer-version-clippy | 1.82.0 |
analyzer-version-cppcheck | 2.16.0 |
analyzer-version-gcc | 14.2.1 |
analyzer-version-gcc-analyzer | 15.0.0 |
analyzer-version-shellcheck | 0.10.0 |
analyzer-version-unicontrol | 0.0.2 |
enabled-plugins | clippy, cppcheck, gcc, shellcheck, unicontrol |
exit-code | 0 |
host | ip-172-16-1-33.us-west-2.compute.internal |
mock-config | fedora-rawhide-gcc-latest-x86_64 |
project-name | libkcompactdisc-24.08.3-1.fc42 |
store-results-to | /tmp/tmpcvysjqia/libkcompactdisc-24.08.3-1.fc42.tar.xz |
time-created | 2024-11-13 01:34:05 |
time-finished | 2024-11-13 01:35:41 |
tool | csmock |
tool-args | '/usr/bin/csmock' '-r' 'fedora-rawhide-gcc-latest-x86_64' '-t' 'clippy,cppcheck,gcc,unicontrol,shellcheck' '-o' '/tmp/tmpcvysjqia/libkcompactdisc-24.08.3-1.fc42.tar.xz' '--gcc-analyze' '--unicontrol-notests' '--unicontrol-bidi-only' '--install=gcc-latest' '--gcc-analyzer-bin=/opt/gcc-latest/bin/gcc' '/tmp/tmpcvysjqia/libkcompactdisc-24.08.3-1.fc42.src.rpm' |
tool-version | csmock-3.7.1.20241107.094801.gb3f0f26.pr_192-1.el9 |