Task #119329 - fixed.err

back to task #119329
download
Error: SHELLCHECK_WARNING (CWE-156):
/usr/bin/plymouth-set-default-theme:47:14: warning[SC2046]: Quote this to prevent word splitting.
#   45|   function read_theme_name_from_file ()
#   46|   {
#   47|->         echo $(grep -v '^#' $1 2> /dev/null |
#   48|                  awk '
#   49|                        BEGIN {

Error: GCC_ANALYZER_WARNING (CWE-457):
plymouth-24.004.60/src/libply-splash-core/ply-input-device.c:253:20: warning[-Wanalyzer-use-of-uninitialized-value]: use of uninitialized value ‘key_state’
plymouth-24.004.60/src/libply-splash-core/ply-input-device.c:208:27: branch_false: following ‘false’ branch...
plymouth-24.004.60/src/libply-splash-core/ply-input-device.c:212:21: branch_false: ...to here
plymouth-24.004.60/src/libply-splash-core/ply-input-device.c:228:25: branch_false: following ‘false’ branch...
plymouth-24.004.60/src/libply-splash-core/ply-input-device.c:249:44: branch_false: ...to here
plymouth-24.004.60/src/libply-splash-core/ply-input-device.c:253:20: danger: use of uninitialized value ‘key_state’ here
#  251|                   symbol = xkb_state_key_get_one_sym (input_device->keyboard_state, keycode);
#  252|   
#  253|->                 if (key_state != PLY_KEY_HELD) {
#  254|                           updated_state = xkb_state_update_key (input_device->keyboard_state, keycode, xkb_key_direction);
#  255|   

Error: COMPILER_WARNING (CWE-457):
plymouth-24.004.60/src/libply-splash-core/ply-input-device.c: scope_hint: In function ‘on_input’
plymouth-24.004.60/src/libply-splash-core/ply-input-device.c:253:20: warning[-Wmaybe-uninitialized]: ‘key_state’ may be used uninitialized
#  253 |                 if (key_state != PLY_KEY_HELD) {
#      |                    ^
plymouth-24.004.60/src/libply-splash-core/ply-input-device.c:193:37: note: ‘key_state’ was declared here
#  193 |                 ply_key_direction_t key_state;
#      |                                     ^~~~~~~~~
#  251|                   symbol = xkb_state_key_get_one_sym (input_device->keyboard_state, keycode);
#  252|   
#  253|->                 if (key_state != PLY_KEY_HELD) {
#  254|                           updated_state = xkb_state_update_key (input_device->keyboard_state, keycode, xkb_key_direction);
#  255|   

Error: COMPILER_WARNING (CWE-457):
plymouth-24.004.60/src/libply-splash-core/ply-input-device.c:254:41: warning[-Wmaybe-uninitialized]: ‘xkb_key_direction’ may be used uninitialized
#  254 |                         updated_state = xkb_state_update_key (input_device->keyboard_state, keycode, xkb_key_direction);
#      |                                         ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
plymouth-24.004.60/src/libply-splash-core/ply-input-device.c:194:40: note: ‘xkb_key_direction’ was declared here
#  194 |                 enum xkb_key_direction xkb_key_direction;
#      |                                        ^~~~~~~~~~~~~~~~~
#  252|   
#  253|                   if (key_state != PLY_KEY_HELD) {
#  254|->                         updated_state = xkb_state_update_key (input_device->keyboard_state, keycode, xkb_key_direction);
#  255|   
#  256|                           if ((updated_state & XKB_STATE_LEDS) != 0) {

Error: GCC_ANALYZER_WARNING (CWE-476):
plymouth-24.004.60/src/libply-splash-core/ply-kmsg-reader.c:91:21: warning[-Wanalyzer-null-dereference]: dereference of NULL ‘msgptr’
plymouth-24.004.60/src/libply-splash-core/ply-kmsg-reader.c:78:12: branch_true: following ‘true’ branch...
plymouth-24.004.60/src/libply-splash-core/ply-kmsg-reader.c:87:26: branch_true: ...to here
plymouth-24.004.60/src/libply-splash-core/ply-kmsg-reader.c:91:21: danger: dereference of NULL ‘msgptr’
#   89|                   /* Messages end in \n, any following lines are machine readable. Actual multiline messages are expanded with unhexmangle_to_buffer */
#   90|                   msgptr = strchr (message, '\n');
#   91|->                 if (*msgptr && *msgptr != '\n')
#   92|                           msgptr--;
#   93|   

Error: COMPILER_WARNING (CWE-252):
plymouth-24.004.60/src/libply-splash-core/ply-kmsg-reader.c: scope_hint: In function ‘handle_kmsg_message’
plymouth-24.004.60/src/libply-splash-core/ply-kmsg-reader.c:132:17: warning[-Wunused-result]: ignoring return value of ‘asprintf’ declared with attribute ‘warn_unused_result’
#  132 |                 asprintf (&format_begin, "\033[0;%i;%im", bold_enabled, color);
#      |                 ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
#  130|                           break;
#  131|                   }
#  132|->                 asprintf (&format_begin, "\033[0;%i;%im", bold_enabled, color);
#  133|   
#  134|                   message_substr = strtok_r (message, "\n", &saveptr);

Error: COMPILER_WARNING (CWE-563):
plymouth-24.004.60/src/libply-splash-core/ply-keyboard.h:29: included_from: Included from here.
plymouth-24.004.60/src/libply-splash-core/ply-keyboard.c:22: included_from: Included from here.
plymouth-24.004.60/src/libply-splash-core/ply-keyboard.c: scope_hint: In function ‘process_backspace’
plymouth-24.004.60/src/libply/ply-buffer.h:60:20: warning[-Wunused-value]: value computed is not used
#   60 |              !_ran && (*bytes = (char *) ply_buffer_get_bytes (buffer),        \
#      |                    ^~
plymouth-24.004.60/src/libply-splash-core/ply-keyboard.c:161:9: note: in expansion of macro ‘ply_buffer_borrow_bytes’
#  161 |         ply_buffer_borrow_bytes (keyboard->line_buffer, &bytes, &size, &capacity) {
#      |         ^~~~~~~~~~~~~~~~~~~~~~~
#   58|   #define ply_buffer_borrow_bytes(buffer, bytes, size, capacity)                 \
#   59|           for (bool _ran = false;                                                \
#   60|->              !_ran && (*bytes = (char *) ply_buffer_get_bytes (buffer),        \
#   61|                          *size = ply_buffer_get_size (buffer),                   \
#   62|                          *capacity = ply_buffer_get_capacity (buffer)),          \

Error: CPPCHECK_WARNING (CWE-476):
plymouth-24.004.60/src/plugins/splash/fade-throbber/plugin.c:251: warning[nullPointerOutOfMemory]: If memory allocation fails, then there is a possible null pointer dereference: plugin
#  249|   
#  250|           /* Likely only able to set the font if the font is in the initrd */
#  251|->         plugin->monospace_font = ply_key_file_get_value (key_file, "two-step", "MonospaceFont");
#  252|   
#  253|           if (plugin->monospace_font == NULL)

Error: CPPCHECK_WARNING (CWE-476):
plymouth-24.004.60/src/plugins/splash/space-flares/plugin.c:630: warning[nullPointerOutOfMemory]: If memory allocation fails, then there is a possible null pointer dereference: plugin
#  628|   
#  629|           /* Likely only able to set the font if the font is in the initrd */
#  630|->         plugin->monospace_font = ply_key_file_get_value (key_file, "two-step", "MonospaceFont");
#  631|   
#  632|           if (plugin->monospace_font == NULL)