Fixed findings
List of Findings
Error: SHELLCHECK_WARNING (CWE-88): [#def1]
/usr/bin/fsadm:135:2: error[SC2068]: Double quote array expansions to avoid re-splitting elements.
Error: SHELLCHECK_WARNING (CWE-88): [#def2]
/usr/bin/fsadm:140:2: error[SC2068]: Double quote array expansions to avoid re-splitting elements.
Error: SHELLCHECK_WARNING (CWE-758): [#def3]
/usr/bin/lvm_import_vdo:33:33: error[SC2218]: This function is only defined later. Move the definition up.
Error: COMPILER_WARNING (CWE-704): [#def4]
LVM2.2.03.34/daemons/dmeventd/plugins/vdo/dmeventd_vdo.c: scope_hint: In function ‘register_device’
LVM2.2.03.34/daemons/dmeventd/plugins/vdo/dmeventd_vdo.c:344:27: warning[-Wdiscarded-qualifiers]: assignment discards ‘const’ qualifier from pointer target type
Error: COMPILER_WARNING (CWE-704): [#def5]
LVM2.2.03.34/daemons/dmeventd/plugins/vdo/dmeventd_vdo.c:344:27: warning[-Wdiscarded-qualifiers]: assignment discards ‘const’ qualifier from pointer target type
Error: GCC_ANALYZER_WARNING (CWE-775): [#def6]
LVM2.2.03.34/daemons/lvmlockd/lvmlockd-sanlock.c:394:59: warning[-Wanalyzer-file-leak]: leak of FILE ‘fopen(&path, "w")’
LVM2.2.03.34/daemons/lvmlockd/lvmlockd-sanlock.c:386:12: branch_false: following ‘false’ branch...
LVM2.2.03.34/daemons/lvmlockd/lvmlockd-sanlock.c:389:20: branch_false: ...to here
LVM2.2.03.34/daemons/lvmlockd/lvmlockd-sanlock.c:389:20: acquire_resource: opened here
LVM2.2.03.34/daemons/lvmlockd/lvmlockd-sanlock.c:389:12: branch_false: following ‘false’ branch...
LVM2.2.03.34/daemons/lvmlockd/lvmlockd-sanlock.c:394:9: branch_false: ...to here
LVM2.2.03.34/daemons/lvmlockd/lvmlockd-sanlock.c:400:13: throw: if ‘fflush’ throws an exception...
LVM2.2.03.34/daemons/lvmlockd/lvmlockd-sanlock.c:394:59: danger: ‘fopen(&path, "w")’ leaks here; was opened at [(3)](sarif:/runs/0/results/0/codeFlows/0/threadFlows/0/locations/2)
Error: GCC_ANALYZER_WARNING (CWE-401): [#def7]
LVM2.2.03.34/daemons/lvmlockd/lvmlockd-sanlock.c:394:59: warning[-Wanalyzer-malloc-leak]: leak of ‘fopen(&path, "w")’
LVM2.2.03.34/daemons/lvmlockd/lvmlockd-sanlock.c:386:12: branch_false: following ‘false’ branch...
LVM2.2.03.34/daemons/lvmlockd/lvmlockd-sanlock.c:389:20: branch_false: ...to here
LVM2.2.03.34/daemons/lvmlockd/lvmlockd-sanlock.c:389:20: acquire_memory: allocated here
LVM2.2.03.34/daemons/lvmlockd/lvmlockd-sanlock.c:389:12: branch_false: following ‘false’ branch...
LVM2.2.03.34/daemons/lvmlockd/lvmlockd-sanlock.c:394:9: branch_false: ...to here
LVM2.2.03.34/daemons/lvmlockd/lvmlockd-sanlock.c:400:13: throw: if ‘fflush’ throws an exception...
LVM2.2.03.34/daemons/lvmlockd/lvmlockd-sanlock.c:394:59: danger: ‘fopen(&path, "w")’ leaks here; was allocated at [(3)](sarif:/runs/0/results/1/codeFlows/0/threadFlows/0/locations/2)
Error: COMPILER_WARNING (CWE-704): [#def8]
LVM2.2.03.34/device_mapper/libdm-common.c: scope_hint: In function ‘dm_task_set_name’
LVM2.2.03.34/device_mapper/libdm-common.c:674:18: warning[-Wdiscarded-qualifiers]: assignment discards ‘const’ qualifier from pointer target type
Error: COMPILER_WARNING (CWE-704): [#def9]
LVM2.2.03.34/device_mapper/libdm-common.c:674:18: warning[-Wdiscarded-qualifiers]: assignment discards ‘const’ qualifier from pointer target type
Error: COMPILER_WARNING (CWE-704): [#def10]
LVM2.2.03.34/device_mapper/libdm-common.c: scope_hint: In function ‘_mountinfo_parse_line’
LVM2.2.03.34/device_mapper/libdm-common.c:1769:37: warning[-Wdiscarded-qualifiers]: assignment discards ‘const’ qualifier from pointer target type
Error: COMPILER_WARNING (CWE-704): [#def11]
LVM2.2.03.34/device_mapper/libdm-common.c:1769:37: warning[-Wdiscarded-qualifiers]: assignment discards ‘const’ qualifier from pointer target type
Error: GCC_ANALYZER_WARNING (CWE-401): [#def12]
LVM2.2.03.34/lib/activate/dev_manager.c:2443:26: warning[-Wanalyzer-malloc-leak]: leak of ‘opendir(&sysfs_path)’
LVM2.2.03.34/lib/activate/dev_manager.c:3980:12: enter_function: entry to ‘_tree_action’
LVM2.2.03.34/lib/activate/dev_manager.c:4013:17: call_function: calling ‘_create_partial_dtree’ from ‘_tree_action’
Error: GCC_ANALYZER_WARNING (CWE-401): [#def13]
LVM2.2.03.34/lib/commands/toolcontext.c:1653:9: warning[-Wanalyzer-malloc-leak]: leak of ‘calloc(1, 18440)’
LVM2.2.03.34/lib/commands/toolcontext.c:1629:21: enter_function: entry to ‘create_toolcontext’
LVM2.2.03.34/lib/commands/toolcontext.c:1649:21: call_function: inlined call to ‘zalloc’ from ‘create_toolcontext’
LVM2.2.03.34/lib/commands/toolcontext.c:1649:12: branch_false: following ‘false’ branch...
LVM2.2.03.34/lib/commands/toolcontext.c:1653:9: branch_false: ...to here
LVM2.2.03.34/lib/commands/toolcontext.c:1662:9: throw: if ‘dm_list_init’ throws an exception...
LVM2.2.03.34/lib/commands/toolcontext.c:1653:9: danger: ‘calloc(1, 18440)’ leaks here; was allocated at [(3)](sarif:/runs/0/results/2/codeFlows/0/threadFlows/0/locations/2)
Error: GCC_ANALYZER_WARNING (CWE-775): [#def14]
LVM2.2.03.34/lib/device/device_id.c:1195:9: warning[-Wanalyzer-file-leak]: leak of FILE ‘fopen(&*cmd.devices_file_path, "r")’
LVM2.2.03.34/lib/device/device_id.c:1211:5: enter_function: entry to ‘device_ids_read’
LVM2.2.03.34/lib/device/device_id.c:1238:12: branch_false: following ‘false’ branch...
LVM2.2.03.34/lib/device/device_id.c:1244:9: branch_false: ...to here
LVM2.2.03.34/lib/device/device_id.c:1246:20: acquire_resource: opened here
LVM2.2.03.34/lib/device/device_id.c:1246:12: branch_false: following ‘false’ branch...
LVM2.2.03.34/lib/device/device_id.c:1246:12: branch_false: ...to here
LVM2.2.03.34/lib/device/device_id.c:1251:16: branch_true: following ‘true’ branch...
LVM2.2.03.34/lib/device/device_id.c:1254:22: branch_true: ...to here
LVM2.2.03.34/lib/device/device_id.c:1259:20: branch_true: following ‘true’ branch...
LVM2.2.03.34/lib/device/device_id.c:1260:25: branch_true: ...to here
LVM2.2.03.34/lib/device/device_id.c:1260:25: call_function: calling ‘_copy_idline_str’ from ‘device_ids_read’
LVM2.2.03.34/lib/device/device_id.c:1260:25: return_function: returning to ‘device_ids_read’ from ‘_copy_idline_str’
LVM2.2.03.34/lib/device/device_id.c:1263:28: branch_true: following ‘true’ branch...
LVM2.2.03.34/lib/device/device_id.c:1264:33: branch_true: ...to here
LVM2.2.03.34/lib/device/device_id.c:1264:33: throw: if ‘print_log’ throws an exception...
LVM2.2.03.34/lib/device/device_id.c:1195:9: danger: ‘fopen(&*cmd.devices_file_path, "r")’ leaks here; was opened at [(4)](sarif:/runs/0/results/0/codeFlows/0/threadFlows/0/locations/3)
Error: GCC_ANALYZER_WARNING (CWE-401): [#def15]
LVM2.2.03.34/lib/device/device_id.c:1195:9: warning[-Wanalyzer-malloc-leak]: leak of ‘fopen(&*cmd.devices_file_path, "r")’
LVM2.2.03.34/lib/device/device_id.c:1211:5: enter_function: entry to ‘device_ids_read’
LVM2.2.03.34/lib/device/device_id.c:1238:12: branch_false: following ‘false’ branch...
LVM2.2.03.34/lib/device/device_id.c:1244:9: branch_false: ...to here
LVM2.2.03.34/lib/device/device_id.c:1246:20: acquire_memory: allocated here
LVM2.2.03.34/lib/device/device_id.c:1246:12: branch_false: following ‘false’ branch...
LVM2.2.03.34/lib/device/device_id.c:1246:12: branch_false: ...to here
LVM2.2.03.34/lib/device/device_id.c:1251:16: branch_true: following ‘true’ branch...
LVM2.2.03.34/lib/device/device_id.c:1254:22: branch_true: ...to here
LVM2.2.03.34/lib/device/device_id.c:1259:20: branch_true: following ‘true’ branch...
LVM2.2.03.34/lib/device/device_id.c:1260:25: branch_true: ...to here
LVM2.2.03.34/lib/device/device_id.c:1260:25: call_function: calling ‘_copy_idline_str’ from ‘device_ids_read’
LVM2.2.03.34/lib/device/device_id.c:1260:25: return_function: returning to ‘device_ids_read’ from ‘_copy_idline_str’
LVM2.2.03.34/lib/device/device_id.c:1263:28: branch_true: following ‘true’ branch...
LVM2.2.03.34/lib/device/device_id.c:1264:33: branch_true: ...to here
LVM2.2.03.34/lib/device/device_id.c:1264:33: throw: if ‘print_log’ throws an exception...
LVM2.2.03.34/lib/device/device_id.c:1195:9: danger: ‘fopen(&*cmd.devices_file_path, "r")’ leaks here; was allocated at [(4)](sarif:/runs/0/results/1/codeFlows/0/threadFlows/0/locations/3)
Error: GCC_ANALYZER_WARNING (CWE-775): [#def16]
LVM2.2.03.34/lib/device/device_id.c:1270:21: warning[-Wanalyzer-file-leak]: leak of FILE ‘fopen(&*cmd.devices_file_path, "r")’
LVM2.2.03.34/lib/device/device_id.c:1238:12: branch_false: following ‘false’ branch...
LVM2.2.03.34/lib/device/device_id.c:1244:9: branch_false: ...to here
LVM2.2.03.34/lib/device/device_id.c:1246:20: acquire_resource: opened here
LVM2.2.03.34/lib/device/device_id.c:1246:12: branch_false: following ‘false’ branch...
LVM2.2.03.34/lib/device/device_id.c:1246:12: branch_false: ...to here
LVM2.2.03.34/lib/device/device_id.c:1251:16: branch_true: following ‘true’ branch...
LVM2.2.03.34/lib/device/device_id.c:1254:22: branch_true: ...to here
LVM2.2.03.34/lib/device/device_id.c:1259:20: branch_false: following ‘false’ branch...
LVM2.2.03.34/lib/device/device_id.c:1270:21: branch_false: ...to here
LVM2.2.03.34/lib/device/device_id.c:1270:20: branch_false: following ‘false’ branch...
LVM2.2.03.34/lib/device/device_id.c:1274:22: branch_false: ...to here
LVM2.2.03.34/lib/device/device_id.c:1274:20: branch_false: following ‘false’ branch...
LVM2.2.03.34/lib/device/device_id.c:1277:56: branch_false: ...to here
LVM2.2.03.34/lib/device/device_id.c:1277:24: throw: if ‘calc_crc’ throws an exception...
LVM2.2.03.34/lib/device/device_id.c:1270:21: danger: ‘fopen(&*cmd.devices_file_path, "r")’ leaks here; was opened at [(3)](sarif:/runs/0/results/18/codeFlows/0/threadFlows/0/locations/2)
Error: GCC_ANALYZER_WARNING (CWE-401): [#def17]
LVM2.2.03.34/lib/device/device_id.c:1270:21: warning[-Wanalyzer-malloc-leak]: leak of ‘fopen(&*cmd.devices_file_path, "r")’
LVM2.2.03.34/lib/device/device_id.c:1238:12: branch_false: following ‘false’ branch...
LVM2.2.03.34/lib/device/device_id.c:1244:9: branch_false: ...to here
LVM2.2.03.34/lib/device/device_id.c:1246:20: acquire_memory: allocated here
LVM2.2.03.34/lib/device/device_id.c:1246:12: branch_false: following ‘false’ branch...
LVM2.2.03.34/lib/device/device_id.c:1246:12: branch_false: ...to here
LVM2.2.03.34/lib/device/device_id.c:1251:16: branch_true: following ‘true’ branch...
LVM2.2.03.34/lib/device/device_id.c:1254:22: branch_true: ...to here
LVM2.2.03.34/lib/device/device_id.c:1259:20: branch_false: following ‘false’ branch...
LVM2.2.03.34/lib/device/device_id.c:1270:21: branch_false: ...to here
LVM2.2.03.34/lib/device/device_id.c:1270:20: branch_false: following ‘false’ branch...
LVM2.2.03.34/lib/device/device_id.c:1274:22: branch_false: ...to here
LVM2.2.03.34/lib/device/device_id.c:1274:20: branch_false: following ‘false’ branch...
LVM2.2.03.34/lib/device/device_id.c:1277:56: branch_false: ...to here
LVM2.2.03.34/lib/device/device_id.c:1277:24: throw: if ‘calc_crc’ throws an exception...
LVM2.2.03.34/lib/device/device_id.c:1270:21: danger: ‘fopen(&*cmd.devices_file_path, "r")’ leaks here; was allocated at [(3)](sarif:/runs/0/results/19/codeFlows/0/threadFlows/0/locations/2)
Error: GCC_ANALYZER_WARNING (CWE-401): [#def18]
LVM2.2.03.34/lib/device/device_id.c:2577:45: warning[-Wanalyzer-malloc-leak]: leak of ‘calloc(1, 32)’
LVM2.2.03.34/lib/device/device_id.c:2517:12: enter_function: entry to ‘_match_du_to_dev’
LVM2.2.03.34/lib/device/device_id.c:2554:12: branch_false: following ‘false’ branch...
LVM2.2.03.34/lib/device/device_id.c:2561:21: branch_false: ...to here
LVM2.2.03.34/lib/device/device_id.c:2561:12: branch_false: following ‘false’ branch...
LVM2.2.03.34/lib/device/device_id.c:2569:13: branch_false: ...to here
LVM2.2.03.34/lib/device/device_id.c:2569:12: branch_true: following ‘true’ branch...
LVM2.2.03.34/lib/device/device_id.c:2570:30: branch_true: ...to here
LVM2.2.03.34/lib/device/device_id.c:2574:36: call_function: inlined call to ‘zalloc’ from ‘_match_du_to_dev’
LVM2.2.03.34/lib/device/device_id.c:2574:28: branch_false: following ‘false’ branch...
LVM2.2.03.34/lib/device/device_id.c:2576:25: branch_false: ...to here
LVM2.2.03.34/lib/device/device_id.c:2578:25: throw: if ‘dm_list_add’ throws an exception...
LVM2.2.03.34/lib/device/device_id.c:2577:45: danger: ‘calloc(1, 32)’ leaks here; was allocated at [(9)](sarif:/runs/0/results/36/codeFlows/0/threadFlows/0/locations/8)
Error: GCC_ANALYZER_WARNING (CWE-401): [#def19]
LVM2.2.03.34/lib/device/device_id.c:2578:25: warning[-Wanalyzer-malloc-leak]: leak of ‘<unknown>’
LVM2.2.03.34/lib/device/device_id.c:2554:12: branch_false: following ‘false’ branch...
LVM2.2.03.34/lib/device/device_id.c:2561:21: branch_false: ...to here
LVM2.2.03.34/lib/device/device_id.c:2561:12: branch_false: following ‘false’ branch...
LVM2.2.03.34/lib/device/device_id.c:2569:13: branch_false: ...to here
LVM2.2.03.34/lib/device/device_id.c:2569:12: branch_true: following ‘true’ branch...
LVM2.2.03.34/lib/device/device_id.c:2570:30: branch_true: ...to here
LVM2.2.03.34/lib/device/device_id.c:2574:28: branch_false: following ‘false’ branch...
LVM2.2.03.34/lib/device/device_id.c:2576:25: branch_false: ...to here
LVM2.2.03.34/lib/device/device_id.c:2577:38: acquire_memory: allocated here
LVM2.2.03.34/lib/device/device_id.c:2578:25: throw: if ‘dm_list_add’ throws an exception...
LVM2.2.03.34/lib/device/device_id.c:2578:25: danger: ‘<unknown>’ leaks here; was allocated at [(9)](sarif:/runs/0/results/37/codeFlows/0/threadFlows/0/locations/8)
Error: GCC_ANALYZER_WARNING (CWE-688): [#def20]
LVM2.2.03.34/lib/device/filesystem.c:191:22: warning[-Wanalyzer-null-argument]: use of NULL ‘opendir(&devices_path)’ where non-null expected
LVM2.2.03.34/lib/device/filesystem.c:172:12: branch_false: following ‘false’ branch...
LVM2.2.03.34/lib/device/filesystem.c:179:20: branch_false: ...to here
LVM2.2.03.34/lib/device/filesystem.c:179:20: acquire_memory: allocated here
LVM2.2.03.34/lib/device/filesystem.c:179:12: release_memory: assuming ‘opendir(&devices_path)’ is NULL
LVM2.2.03.34/lib/device/filesystem.c:179:12: branch_true: following ‘true’ branch...
LVM2.2.03.34/lib/device/filesystem.c:180:21: branch_true: ...to here
LVM2.2.03.34/lib/device/filesystem.c:180:20: branch_false: following ‘false’ branch...
LVM2.2.03.34/lib/device/filesystem.c:180:20: branch_false: ...to here
LVM2.2.03.34/lib/device/filesystem.c:191:22: danger: argument 1 (‘opendir(&devices_path)’) NULL where non-null expected
Error: GCC_ANALYZER_WARNING (CWE-775): [#def21]
LVM2.2.03.34/lib/device/persist.c:241:13: warning[-Wanalyzer-file-leak]: leak of FILE ‘fopen(&path, "w")’
LVM2.2.03.34/lib/device/persist.c:231:12: branch_false: following ‘false’ branch...
LVM2.2.03.34/lib/device/persist.c:234:20: branch_false: ...to here
LVM2.2.03.34/lib/device/persist.c:234:20: acquire_resource: opened here
LVM2.2.03.34/lib/device/persist.c:234:12: branch_false: following ‘false’ branch...
LVM2.2.03.34/lib/device/persist.c:239:9: branch_false: ...to here
LVM2.2.03.34/lib/device/persist.c:241:13: throw: if ‘fflush’ throws an exception...
LVM2.2.03.34/lib/device/persist.c:241:13: danger: ‘fopen(&path, "w")’ leaks here; was opened at [(3)](sarif:/runs/0/results/2/codeFlows/0/threadFlows/0/locations/2)
Error: GCC_ANALYZER_WARNING (CWE-401): [#def22]
LVM2.2.03.34/lib/device/persist.c:241:13: warning[-Wanalyzer-malloc-leak]: leak of ‘fopen(&path, "w")’
LVM2.2.03.34/lib/device/persist.c:231:12: branch_false: following ‘false’ branch...
LVM2.2.03.34/lib/device/persist.c:234:20: branch_false: ...to here
LVM2.2.03.34/lib/device/persist.c:234:20: acquire_memory: allocated here
LVM2.2.03.34/lib/device/persist.c:234:12: branch_false: following ‘false’ branch...
LVM2.2.03.34/lib/device/persist.c:239:9: branch_false: ...to here
LVM2.2.03.34/lib/device/persist.c:241:13: throw: if ‘fflush’ throws an exception...
LVM2.2.03.34/lib/device/persist.c:241:13: danger: ‘fopen(&path, "w")’ leaks here; was allocated at [(3)](sarif:/runs/0/results/3/codeFlows/0/threadFlows/0/locations/2)
Error: GCC_ANALYZER_WARNING (CWE-775): [#def23]
LVM2.2.03.34/lib/device/persist.c:242:17: warning[-Wanalyzer-file-leak]: leak of FILE ‘fopen(&path, "w")’
LVM2.2.03.34/lib/device/persist.c:231:12: branch_false: following ‘false’ branch...
LVM2.2.03.34/lib/device/persist.c:234:20: branch_false: ...to here
LVM2.2.03.34/lib/device/persist.c:234:20: acquire_resource: opened here
LVM2.2.03.34/lib/device/persist.c:234:12: branch_false: following ‘false’ branch...
LVM2.2.03.34/lib/device/persist.c:239:9: branch_false: ...to here
LVM2.2.03.34/lib/device/persist.c:241:12: branch_true: following ‘true’ branch...
LVM2.2.03.34/lib/device/persist.c:242:17: branch_true: ...to here
LVM2.2.03.34/lib/device/persist.c:242:17: throw: if ‘print_log’ throws an exception...
LVM2.2.03.34/lib/device/persist.c:242:17: danger: ‘fopen(&path, "w")’ leaks here; was opened at [(3)](sarif:/runs/0/results/4/codeFlows/0/threadFlows/0/locations/2)
Error: GCC_ANALYZER_WARNING (CWE-401): [#def24]
LVM2.2.03.34/lib/device/persist.c:242:17: warning[-Wanalyzer-malloc-leak]: leak of ‘fopen(&path, "w")’
LVM2.2.03.34/lib/device/persist.c:231:12: branch_false: following ‘false’ branch...
LVM2.2.03.34/lib/device/persist.c:234:20: branch_false: ...to here
LVM2.2.03.34/lib/device/persist.c:234:20: acquire_memory: allocated here
LVM2.2.03.34/lib/device/persist.c:234:12: branch_false: following ‘false’ branch...
LVM2.2.03.34/lib/device/persist.c:239:9: branch_false: ...to here
LVM2.2.03.34/lib/device/persist.c:241:12: branch_true: following ‘true’ branch...
LVM2.2.03.34/lib/device/persist.c:242:17: branch_true: ...to here
LVM2.2.03.34/lib/device/persist.c:242:17: throw: if ‘print_log’ throws an exception...
LVM2.2.03.34/lib/device/persist.c:242:17: danger: ‘fopen(&path, "w")’ leaks here; was allocated at [(3)](sarif:/runs/0/results/5/codeFlows/0/threadFlows/0/locations/2)
Error: COMPILER_WARNING (CWE-704): [#def25]
LVM2.2.03.34/lib/format_text/format-text.c: scope_hint: In function ‘_vg_write_file’
LVM2.2.03.34/lib/format_text/format-text.c:1303:15: warning[-Wdiscarded-qualifiers]: assignment discards ‘const’ qualifier from pointer target type
Error: COMPILER_WARNING (CWE-704): [#def26]
LVM2.2.03.34/lib/format_text/format-text.c:1303:15: warning[-Wdiscarded-qualifiers]: assignment discards ‘const’ qualifier from pointer target type
Error: COMPILER_WARNING (CWE-704): [#def27]
LVM2.2.03.34/lib/format_text/format-text.c: scope_hint: In function ‘_create_text_context’
LVM2.2.03.34/lib/format_text/format-text.c:2089:18: warning[-Wdiscarded-qualifiers]: assignment discards ‘const’ qualifier from pointer target type
Error: COMPILER_WARNING (CWE-704): [#def28]
LVM2.2.03.34/lib/format_text/format-text.c:2089:18: warning[-Wdiscarded-qualifiers]: assignment discards ‘const’ qualifier from pointer target type
Error: COMPILER_WARNING (CWE-704): [#def29]
LVM2.2.03.34/lib/metadata/raid_manip.c: scope_hint: In function ‘_drop_suffix’
LVM2.2.03.34/lib/metadata/raid_manip.c:175:17: warning[-Wdiscarded-qualifiers]: assignment discards ‘const’ qualifier from pointer target type
Error: COMPILER_WARNING (CWE-704): [#def30]
LVM2.2.03.34/lib/metadata/raid_manip.c:175:17: warning[-Wdiscarded-qualifiers]: assignment discards ‘const’ qualifier from pointer target type
Error: COMPILER_WARNING (CWE-704): [#def31]
LVM2.2.03.34/lib/misc/lvm-string.c: scope_hint: In function ‘first_substring’
LVM2.2.03.34/lib/misc/lvm-string.c:295:24: warning[-Wdiscarded-qualifiers]: assignment discards ‘const’ qualifier from pointer target type
Error: COMPILER_WARNING (CWE-704): [#def32]
LVM2.2.03.34/lib/misc/lvm-string.c:295:24: warning[-Wdiscarded-qualifiers]: assignment discards ‘const’ qualifier from pointer target type
Error: GCC_ANALYZER_WARNING (CWE-401): [#def33]
LVM2.2.03.34/lib/raid/raid.c:681:25: warning[-Wanalyzer-malloc-leak]: leak of ‘_init_raid_segtype(cmd, & _raid_types[i], get_monitor_dso_path(cmd, 284), monitored)’
LVM2.2.03.34/lib/raid/raid.c:699:5: enter_function: entry to ‘init_raid_segtypes’
LVM2.2.03.34/lib/raid/raid.c:721:21: branch_true: following ‘true’ branch (when ‘i != 21’)...
LVM2.2.03.34/lib/raid/raid.c:722:32: branch_true: ...to here
LVM2.2.03.34/lib/raid/raid.c:722:32: call_function: calling ‘_init_raid_segtype’ from ‘init_raid_segtypes’
LVM2.2.03.34/lib/raid/raid.c:722:32: return_function: returning to ‘init_raid_segtypes’ from ‘_init_raid_segtype’
LVM2.2.03.34/lib/raid/raid.c:722:20: branch_true: following ‘true’ branch...
LVM2.2.03.34/lib/raid/raid.c:723:22: branch_true: ...to here
LVM2.2.03.34/lib/raid/raid.c:681:25: danger: ‘_init_raid_segtype(cmd, & _raid_types[i], get_monitor_dso_path(cmd, 284), monitored)’ leaks here; was allocated at [(7)](sarif:/runs/0/results/1/codeFlows/0/threadFlows/0/locations/6)
Error: GCC_ANALYZER_WARNING (CWE-775): [#def34]
LVM2.2.03.34/libdaemon/server/daemon-server.c:344:12: warning[-Wanalyzer-fd-leak]: leak of file descriptor ‘open("/dev/null", 2)’
LVM2.2.03.34/libdaemon/server/daemon-server.c:338:19: acquire_resource: opened here
LVM2.2.03.34/libdaemon/server/daemon-server.c:338:12: branch_false: following ‘false’ branch...
LVM2.2.03.34/libdaemon/server/daemon-server.c:343:9: branch_false: ...to here
LVM2.2.03.34/libdaemon/server/daemon-server.c:344:12: danger: ‘open("/dev/null", 2)’ leaks here; was opened at [(1)](sarif:/runs/0/results/8/codeFlows/0/threadFlows/0/locations/0)
Error: GCC_ANALYZER_WARNING (CWE-775): [#def35]
LVM2.2.03.34/libdaemon/server/daemon-server.c:350:9: warning[-Wanalyzer-fd-leak]: leak of file descriptor ‘open("/dev/null", 2)’
LVM2.2.03.34/libdaemon/server/daemon-server.c:338:19: acquire_resource: opened here
LVM2.2.03.34/libdaemon/server/daemon-server.c:338:12: branch_false: following ‘false’ branch...
LVM2.2.03.34/libdaemon/server/daemon-server.c:343:9: branch_false: ...to here
LVM2.2.03.34/libdaemon/server/daemon-server.c:344:12: branch_false: following ‘false’ branch...
LVM2.2.03.34/libdaemon/server/daemon-server.c:348:9: branch_false: ...to here
LVM2.2.03.34/libdaemon/server/daemon-server.c:350:9: danger: ‘open("/dev/null", 2)’ leaks here; was opened at [(1)](sarif:/runs/0/results/9/codeFlows/0/threadFlows/0/locations/0)
Error: GCC_ANALYZER_WARNING (CWE-775): [#def36]
LVM2.2.03.34/libdaemon/server/daemon-server.c:381:12: warning[-Wanalyzer-fd-leak]: leak of file descriptor ‘open("/dev/null", 2)’
LVM2.2.03.34/libdaemon/server/daemon-server.c:338:19: acquire_resource: opened here
LVM2.2.03.34/libdaemon/server/daemon-server.c:338:12: branch_false: following ‘false’ branch...
LVM2.2.03.34/libdaemon/server/daemon-server.c:343:9: branch_false: ...to here
LVM2.2.03.34/libdaemon/server/daemon-server.c:344:12: branch_false: following ‘false’ branch...
LVM2.2.03.34/libdaemon/server/daemon-server.c:348:9: branch_false: ...to here
LVM2.2.03.34/libdaemon/server/daemon-server.c:381:12: danger: ‘open("/dev/null", 2)’ leaks here; was opened at [(1)](sarif:/runs/0/results/11/codeFlows/0/threadFlows/0/locations/0)
Error: GCC_ANALYZER_WARNING (CWE-775): [#def37]
LVM2.2.03.34/libdaemon/server/daemon-server.c:386:12: warning[-Wanalyzer-fd-leak]: leak of file descriptor ‘dup2(open("/dev/null", 2), 0)’
LVM2.2.03.34/libdaemon/server/daemon-server.c:338:12: branch_false: following ‘false’ branch...
LVM2.2.03.34/libdaemon/server/daemon-server.c:343:9: branch_false: ...to here
LVM2.2.03.34/libdaemon/server/daemon-server.c:344:12: branch_false: following ‘false’ branch...
LVM2.2.03.34/libdaemon/server/daemon-server.c:348:9: branch_false: ...to here
LVM2.2.03.34/libdaemon/server/daemon-server.c:381:12: branch_false: following ‘false’ branch...
LVM2.2.03.34/libdaemon/server/daemon-server.c:386:14: branch_false: ...to here
LVM2.2.03.34/libdaemon/server/daemon-server.c:386:14: acquire_resource: opened here
LVM2.2.03.34/libdaemon/server/daemon-server.c:386:12: danger: ‘dup2(open("/dev/null", 2), 0)’ leaks here; was opened at [(9)](sarif:/runs/0/results/13/codeFlows/0/threadFlows/0/locations/8)
Error: GCC_ANALYZER_WARNING (CWE-775): [#def38]
LVM2.2.03.34/libdaemon/server/daemon-server.c:386:12: warning[-Wanalyzer-fd-leak]: leak of file descriptor ‘open("/dev/null", 2)’
LVM2.2.03.34/libdaemon/server/daemon-server.c:338:19: acquire_resource: opened here
LVM2.2.03.34/libdaemon/server/daemon-server.c:338:12: branch_false: following ‘false’ branch...
LVM2.2.03.34/libdaemon/server/daemon-server.c:343:9: branch_false: ...to here
LVM2.2.03.34/libdaemon/server/daemon-server.c:344:12: branch_false: following ‘false’ branch...
LVM2.2.03.34/libdaemon/server/daemon-server.c:348:9: branch_false: ...to here
LVM2.2.03.34/libdaemon/server/daemon-server.c:381:12: branch_false: following ‘false’ branch...
LVM2.2.03.34/libdaemon/server/daemon-server.c:386:14: branch_false: ...to here
LVM2.2.03.34/libdaemon/server/daemon-server.c:386:12: danger: ‘open("/dev/null", 2)’ leaks here; was opened at [(1)](sarif:/runs/0/results/12/codeFlows/0/threadFlows/0/locations/0)
Error: GCC_ANALYZER_WARNING (CWE-775): [#def39]
LVM2.2.03.34/libdaemon/server/daemon-server.c:386:13: warning[-Wanalyzer-fd-leak]: leak of file descriptor ‘dup2(open("/dev/null", 2), 1)’
LVM2.2.03.34/libdaemon/server/daemon-server.c:338:12: branch_false: following ‘false’ branch...
LVM2.2.03.34/libdaemon/server/daemon-server.c:343:9: branch_false: ...to here
LVM2.2.03.34/libdaemon/server/daemon-server.c:344:12: branch_false: following ‘false’ branch...
LVM2.2.03.34/libdaemon/server/daemon-server.c:348:9: branch_false: ...to here
LVM2.2.03.34/libdaemon/server/daemon-server.c:381:12: branch_false: following ‘false’ branch...
LVM2.2.03.34/libdaemon/server/daemon-server.c:386:14: branch_false: ...to here
LVM2.2.03.34/libdaemon/server/daemon-server.c:386:12: branch_false: following ‘false’ branch...
LVM2.2.03.34/libdaemon/server/daemon-server.c:387:14: branch_false: ...to here
LVM2.2.03.34/libdaemon/server/daemon-server.c:387:14: acquire_resource: opened here
LVM2.2.03.34/libdaemon/server/daemon-server.c:386:13: danger: ‘dup2(open("/dev/null", 2), 1)’ leaks here; was opened at [(11)](sarif:/runs/0/results/15/codeFlows/0/threadFlows/0/locations/10)
Error: GCC_ANALYZER_WARNING (CWE-775): [#def40]
LVM2.2.03.34/libdaemon/server/daemon-server.c:386:13: warning[-Wanalyzer-fd-leak]: leak of file descriptor ‘dup2(open("/dev/null", 2), 2)’
LVM2.2.03.34/libdaemon/server/daemon-server.c:338:12: branch_false: following ‘false’ branch...
LVM2.2.03.34/libdaemon/server/daemon-server.c:343:9: branch_false: ...to here
LVM2.2.03.34/libdaemon/server/daemon-server.c:344:12: branch_false: following ‘false’ branch...
LVM2.2.03.34/libdaemon/server/daemon-server.c:348:9: branch_false: ...to here
LVM2.2.03.34/libdaemon/server/daemon-server.c:381:12: branch_false: following ‘false’ branch...
LVM2.2.03.34/libdaemon/server/daemon-server.c:386:14: branch_false: ...to here
LVM2.2.03.34/libdaemon/server/daemon-server.c:386:12: branch_false: following ‘false’ branch...
LVM2.2.03.34/libdaemon/server/daemon-server.c:387:14: branch_false: ...to here
LVM2.2.03.34/libdaemon/server/daemon-server.c:386:13: branch_false: following ‘false’ branch...
LVM2.2.03.34/libdaemon/server/daemon-server.c:388:14: branch_false: ...to here
LVM2.2.03.34/libdaemon/server/daemon-server.c:388:14: acquire_resource: opened here
LVM2.2.03.34/libdaemon/server/daemon-server.c:386:13: danger: ‘dup2(open("/dev/null", 2), 2)’ leaks here; was opened at [(13)](sarif:/runs/0/results/17/codeFlows/0/threadFlows/0/locations/12)
Error: GCC_ANALYZER_WARNING (CWE-775): [#def41]
LVM2.2.03.34/libdaemon/server/daemon-server.c:386:13: warning[-Wanalyzer-fd-leak]: leak of file descriptor ‘open("/dev/null", 2)’
LVM2.2.03.34/libdaemon/server/daemon-server.c:338:19: acquire_resource: opened here
LVM2.2.03.34/libdaemon/server/daemon-server.c:338:12: branch_false: following ‘false’ branch...
LVM2.2.03.34/libdaemon/server/daemon-server.c:343:9: branch_false: ...to here
LVM2.2.03.34/libdaemon/server/daemon-server.c:344:12: branch_false: following ‘false’ branch...
LVM2.2.03.34/libdaemon/server/daemon-server.c:348:9: branch_false: ...to here
LVM2.2.03.34/libdaemon/server/daemon-server.c:381:12: branch_false: following ‘false’ branch...
LVM2.2.03.34/libdaemon/server/daemon-server.c:386:14: branch_false: ...to here
LVM2.2.03.34/libdaemon/server/daemon-server.c:386:12: branch_false: following ‘false’ branch...
LVM2.2.03.34/libdaemon/server/daemon-server.c:387:14: branch_false: ...to here
LVM2.2.03.34/libdaemon/server/daemon-server.c:386:13: danger: ‘open("/dev/null", 2)’ leaks here; was opened at [(1)](sarif:/runs/0/results/14/codeFlows/0/threadFlows/0/locations/0)
Error: GCC_ANALYZER_WARNING (CWE-775): [#def42]
LVM2.2.03.34/libdaemon/server/daemon-server.c:386:13: warning[-Wanalyzer-fd-leak]: leak of file descriptor ‘open("/dev/null", 2)’
LVM2.2.03.34/libdaemon/server/daemon-server.c:338:19: acquire_resource: opened here
LVM2.2.03.34/libdaemon/server/daemon-server.c:338:12: branch_false: following ‘false’ branch...
LVM2.2.03.34/libdaemon/server/daemon-server.c:343:9: branch_false: ...to here
LVM2.2.03.34/libdaemon/server/daemon-server.c:344:12: branch_false: following ‘false’ branch...
LVM2.2.03.34/libdaemon/server/daemon-server.c:348:9: branch_false: ...to here
LVM2.2.03.34/libdaemon/server/daemon-server.c:381:12: branch_false: following ‘false’ branch...
LVM2.2.03.34/libdaemon/server/daemon-server.c:386:14: branch_false: ...to here
LVM2.2.03.34/libdaemon/server/daemon-server.c:386:12: branch_false: following ‘false’ branch...
LVM2.2.03.34/libdaemon/server/daemon-server.c:387:14: branch_false: ...to here
LVM2.2.03.34/libdaemon/server/daemon-server.c:386:13: branch_false: following ‘false’ branch...
LVM2.2.03.34/libdaemon/server/daemon-server.c:388:14: branch_false: ...to here
LVM2.2.03.34/libdaemon/server/daemon-server.c:386:13: danger: ‘open("/dev/null", 2)’ leaks here; was opened at [(1)](sarif:/runs/0/results/16/codeFlows/0/threadFlows/0/locations/0)
Error: GCC_ANALYZER_WARNING (CWE-775): [#def43]
LVM2.2.03.34/libdm/dm-tools/dmfilemapd.c:661:20: warning[-Wanalyzer-fd-leak]: leak of file descriptor ‘dup2(open("/dev/null", 2), 0)’
LVM2.2.03.34/libdm/dm-tools/dmfilemapd.c:634:12: branch_false: following ‘false’ branch...
LVM2.2.03.34/libdm/dm-tools/dmfilemapd.c:639:20: branch_false: ...to here
LVM2.2.03.34/libdm/dm-tools/dmfilemapd.c:639:12: branch_false: following ‘false’ branch (when ‘pid >= 0’)...
LVM2.2.03.34/libdm/dm-tools/dmfilemapd.c:644:12: branch_false: ...to here
LVM2.2.03.34/libdm/dm-tools/dmfilemapd.c:644:12: branch_false: following ‘false’ branch (when ‘pid == 0’)...
LVM2.2.03.34/libdm/dm-tools/dmfilemapd.c:650:13: branch_false: ...to here
LVM2.2.03.34/libdm/dm-tools/dmfilemapd.c:650:12: branch_false: following ‘false’ branch...
LVM2.2.03.34/libdm/dm-tools/dmfilemapd.c:655:13: branch_false: ...to here
LVM2.2.03.34/libdm/dm-tools/dmfilemapd.c:655:12: branch_true: following ‘true’ branch...
LVM2.2.03.34/libdm/dm-tools/dmfilemapd.c:656:27: branch_true: ...to here
LVM2.2.03.34/libdm/dm-tools/dmfilemapd.c:656:20: branch_false: following ‘false’ branch...
LVM2.2.03.34/libdm/dm-tools/dmfilemapd.c:661:22: branch_false: ...to here
LVM2.2.03.34/libdm/dm-tools/dmfilemapd.c:661:22: acquire_resource: opened here
LVM2.2.03.34/libdm/dm-tools/dmfilemapd.c:661:20: danger: ‘dup2(open("/dev/null", 2), 0)’ leaks here; was opened at [(13)](sarif:/runs/0/results/7/codeFlows/0/threadFlows/0/locations/12)
Error: GCC_ANALYZER_WARNING (CWE-775): [#def44]
LVM2.2.03.34/libdm/dm-tools/dmfilemapd.c:661:21: warning[-Wanalyzer-fd-leak]: leak of file descriptor ‘dup2(open("/dev/null", 2), 1)’
LVM2.2.03.34/libdm/dm-tools/dmfilemapd.c:634:12: branch_false: following ‘false’ branch...
LVM2.2.03.34/libdm/dm-tools/dmfilemapd.c:639:20: branch_false: ...to here
LVM2.2.03.34/libdm/dm-tools/dmfilemapd.c:639:12: branch_false: following ‘false’ branch (when ‘pid >= 0’)...
LVM2.2.03.34/libdm/dm-tools/dmfilemapd.c:644:12: branch_false: ...to here
LVM2.2.03.34/libdm/dm-tools/dmfilemapd.c:644:12: branch_false: following ‘false’ branch (when ‘pid == 0’)...
LVM2.2.03.34/libdm/dm-tools/dmfilemapd.c:650:13: branch_false: ...to here
LVM2.2.03.34/libdm/dm-tools/dmfilemapd.c:650:12: branch_false: following ‘false’ branch...
LVM2.2.03.34/libdm/dm-tools/dmfilemapd.c:655:13: branch_false: ...to here
LVM2.2.03.34/libdm/dm-tools/dmfilemapd.c:655:12: branch_true: following ‘true’ branch...
LVM2.2.03.34/libdm/dm-tools/dmfilemapd.c:656:27: branch_true: ...to here
LVM2.2.03.34/libdm/dm-tools/dmfilemapd.c:656:20: branch_false: following ‘false’ branch...
LVM2.2.03.34/libdm/dm-tools/dmfilemapd.c:661:22: branch_false: ...to here
LVM2.2.03.34/libdm/dm-tools/dmfilemapd.c:661:20: branch_false: following ‘false’ branch...
LVM2.2.03.34/libdm/dm-tools/dmfilemapd.c:662:22: branch_false: ...to here
LVM2.2.03.34/libdm/dm-tools/dmfilemapd.c:662:22: acquire_resource: opened here
LVM2.2.03.34/libdm/dm-tools/dmfilemapd.c:661:21: danger: ‘dup2(open("/dev/null", 2), 1)’ leaks here; was opened at [(15)](sarif:/runs/0/results/8/codeFlows/0/threadFlows/0/locations/14)
Error: GCC_ANALYZER_WARNING (CWE-775): [#def45]
LVM2.2.03.34/libdm/dm-tools/dmfilemapd.c:661:21: warning[-Wanalyzer-fd-leak]: leak of file descriptor ‘dup2(open("/dev/null", 2), 2)’
LVM2.2.03.34/libdm/dm-tools/dmfilemapd.c:634:12: branch_false: following ‘false’ branch...
LVM2.2.03.34/libdm/dm-tools/dmfilemapd.c:639:20: branch_false: ...to here
LVM2.2.03.34/libdm/dm-tools/dmfilemapd.c:639:12: branch_false: following ‘false’ branch (when ‘pid >= 0’)...
LVM2.2.03.34/libdm/dm-tools/dmfilemapd.c:644:12: branch_false: ...to here
LVM2.2.03.34/libdm/dm-tools/dmfilemapd.c:644:12: branch_false: following ‘false’ branch (when ‘pid == 0’)...
LVM2.2.03.34/libdm/dm-tools/dmfilemapd.c:650:13: branch_false: ...to here
LVM2.2.03.34/libdm/dm-tools/dmfilemapd.c:650:12: branch_false: following ‘false’ branch...
LVM2.2.03.34/libdm/dm-tools/dmfilemapd.c:655:13: branch_false: ...to here
LVM2.2.03.34/libdm/dm-tools/dmfilemapd.c:655:12: branch_true: following ‘true’ branch...
LVM2.2.03.34/libdm/dm-tools/dmfilemapd.c:656:27: branch_true: ...to here
LVM2.2.03.34/libdm/dm-tools/dmfilemapd.c:656:20: branch_false: following ‘false’ branch...
LVM2.2.03.34/libdm/dm-tools/dmfilemapd.c:661:22: branch_false: ...to here
LVM2.2.03.34/libdm/dm-tools/dmfilemapd.c:661:20: branch_false: following ‘false’ branch...
LVM2.2.03.34/libdm/dm-tools/dmfilemapd.c:662:22: branch_false: ...to here
LVM2.2.03.34/libdm/dm-tools/dmfilemapd.c:661:21: branch_false: following ‘false’ branch...
LVM2.2.03.34/libdm/dm-tools/dmfilemapd.c:663:22: branch_false: ...to here
LVM2.2.03.34/libdm/dm-tools/dmfilemapd.c:663:22: acquire_resource: opened here
LVM2.2.03.34/libdm/dm-tools/dmfilemapd.c:661:21: danger: ‘dup2(open("/dev/null", 2), 2)’ leaks here; was opened at [(17)](sarif:/runs/0/results/9/codeFlows/0/threadFlows/0/locations/16)
Error: COMPILER_WARNING (CWE-704): [#def46]
LVM2.2.03.34/libdm/libdm-common.c: scope_hint: In function ‘dm_task_set_name’
LVM2.2.03.34/libdm/libdm-common.c:672:18: warning[-Wdiscarded-qualifiers]: assignment discards ‘const’ qualifier from pointer target type
Error: COMPILER_WARNING (CWE-704): [#def47]
LVM2.2.03.34/libdm/libdm-common.c:672:18: warning[-Wdiscarded-qualifiers]: assignment discards ‘const’ qualifier from pointer target type
Error: COMPILER_WARNING (CWE-704): [#def48]
LVM2.2.03.34/libdm/libdm-common.c: scope_hint: In function ‘_mountinfo_parse_line’
LVM2.2.03.34/libdm/libdm-common.c:1767:37: warning[-Wdiscarded-qualifiers]: assignment discards ‘const’ qualifier from pointer target type
Error: COMPILER_WARNING (CWE-704): [#def49]
LVM2.2.03.34/libdm/libdm-common.c:1767:37: warning[-Wdiscarded-qualifiers]: assignment discards ‘const’ qualifier from pointer target type
Error: COMPILER_WARNING (CWE-704): [#def50]
LVM2.2.03.34/libdm/libdm-stats.c: scope_hint: In function ‘_stats_parse_histogram_spec’
LVM2.2.03.34/libdm/libdm-stats.c:857:16: warning[-Wdiscarded-qualifiers]: assignment discards ‘const’ qualifier from pointer target type
Error: COMPILER_WARNING (CWE-704): [#def51]
LVM2.2.03.34/libdm/libdm-stats.c:857:16: warning[-Wdiscarded-qualifiers]: assignment discards ‘const’ qualifier from pointer target type
Error: COMPILER_WARNING (CWE-704): [#def52]
LVM2.2.03.34/tools/command.c: scope_hint: In function ‘_add_oo_definition_line’
LVM2.2.03.34/tools/command.c:657:15: warning[-Wdiscarded-qualifiers]: assignment discards ‘const’ qualifier from pointer target type
Error: COMPILER_WARNING (CWE-704): [#def53]
LVM2.2.03.34/tools/command.c:657:15: warning[-Wdiscarded-qualifiers]: assignment discards ‘const’ qualifier from pointer target type
Error: GCC_ANALYZER_WARNING (CWE-401): [#def54]
LVM2.2.03.34/tools/pvck.c:968:33: warning[-Wanalyzer-malloc-leak]: leak of ‘vgname’
LVM2.2.03.34/tools/pvck.c:885:12: enter_function: entry to ‘_dump_current_text’
LVM2.2.03.34/tools/pvck.c:901:12: branch_false: following ‘false’ branch...
LVM2.2.03.34/tools/pvck.c:915:13: branch_false: ...to here
LVM2.2.03.34/tools/pvck.c:939:22: call_function: calling ‘_read_bytes’ from ‘_dump_current_text’
LVM2.2.03.34/tools/pvck.c:939:22: return_function: returning to ‘_dump_current_text’ from ‘_read_bytes’
LVM2.2.03.34/tools/pvck.c:939:20: branch_true: following ‘true’ branch...
LVM2.2.03.34/tools/pvck.c:947:17: branch_true: ...to here
LVM2.2.03.34/tools/pvck.c:955:12: branch_false: following ‘false’ branch...
LVM2.2.03.34/tools/pvck.c:959:22: branch_false: ...to here
LVM2.2.03.34/tools/pvck.c:959:20: branch_false: following ‘false’ branch...
LVM2.2.03.34/tools/pvck.c:965:29: branch_false: ...to here
LVM2.2.03.34/tools/pvck.c:965:28: branch_true: following ‘true’ branch...
LVM2.2.03.34/tools/pvck.c:966:42: acquire_memory: allocated here
LVM2.2.03.34/tools/pvck.c:967:28: branch_true: following ‘true’ branch...
LVM2.2.03.34/tools/pvck.c:968:33: throw: if ‘dm_config_get_uint32’ throws an exception...
LVM2.2.03.34/tools/pvck.c:968:33: danger: ‘vgname’ leaks here; was allocated at [(17)](sarif:/runs/0/results/35/codeFlows/0/threadFlows/0/locations/16)
Error: COMPILER_WARNING (CWE-704): [#def55]
LVM2.2.03.34/tools/toollib.c: scope_hint: In function ‘_extract_vgname’
LVM2.2.03.34/tools/toollib.c:411:23: warning[-Wdiscarded-qualifiers]: assignment discards ‘const’ qualifier from pointer target type
Error: COMPILER_WARNING (CWE-704): [#def56]
LVM2.2.03.34/tools/toollib.c:411:23: warning[-Wdiscarded-qualifiers]: assignment discards ‘const’ qualifier from pointer target type
Scan Properties
| analyzer-version-clippy | 1.92.0 |
| analyzer-version-cppcheck | 2.19.1 |
| analyzer-version-gcc | 16.0.0 |
| analyzer-version-gcc-analyzer | 16.0.0 |
| analyzer-version-shellcheck | 0.11.0 |
| analyzer-version-unicontrol | 0.0.2 |
| diffbase-analyzer-version-clippy | 1.92.0 |
| diffbase-analyzer-version-cppcheck | 2.19.1 |
| diffbase-analyzer-version-gcc | 16.0.0 |
| diffbase-analyzer-version-gcc-analyzer | 16.0.0 |
| diffbase-analyzer-version-shellcheck | 0.11.0 |
| diffbase-analyzer-version-unicontrol | 0.0.2 |
| diffbase-enabled-plugins | clippy, cppcheck, gcc, shellcheck, unicontrol |
| diffbase-exit-code | 0 |
| diffbase-host | ip-172-16-1-127.us-west-2.compute.internal |
| diffbase-known-false-positives | /usr/share/csmock/known-false-positives.js |
| diffbase-known-false-positives-rpm | known-false-positives-0.0.0.20250521.132812.g8eff701.main-1.el9.noarch |
| diffbase-mock-config | fedora-rawhide-x86_64 |
| diffbase-project-name | lvm2-2.03.38-1.fc44 |
| diffbase-store-results-to | /tmp/tmpd3bw0_ae/lvm2-2.03.38-1.fc44.tar.xz |
| diffbase-time-created | 2026-01-08 19:28:36 |
| diffbase-time-finished | 2026-01-08 19:32:37 |
| diffbase-tool | csmock |
| diffbase-tool-args | '/usr/bin/csmock' '-r' 'fedora-rawhide-x86_64' '-t' 'gcc,cppcheck,clippy,shellcheck,unicontrol' '-o' '/tmp/tmpd3bw0_ae/lvm2-2.03.38-1.fc44.tar.xz' '--gcc-analyze' '--unicontrol-notests' '--unicontrol-bidi-only' '--install' 'pam' '--gcc-analyzer-bin=/usr/bin/gcc' '/tmp/tmpd3bw0_ae/lvm2-2.03.38-1.fc44.src.rpm' |
| diffbase-tool-version | csmock-3.8.3.20251215.161544.g62de9a5-1.el9 |
| enabled-plugins | clippy, cppcheck, gcc, shellcheck, unicontrol |
| exit-code | 0 |
| host | ip-172-16-1-127.us-west-2.compute.internal |
| known-false-positives | /usr/share/csmock/known-false-positives.js |
| known-false-positives-rpm | known-false-positives-0.0.0.20250521.132812.g8eff701.main-1.el9.noarch |
| mock-config | fedora-rawhide-x86_64 |
| project-name | lvm2-2.03.34-2.fc43 |
| store-results-to | /tmp/tmpwiice9v_/lvm2-2.03.34-2.fc43.tar.xz |
| time-created | 2026-01-08 19:23:29 |
| time-finished | 2026-01-08 19:27:57 |
| title | Fixed findings |
| tool | csmock |
| tool-args | '/usr/bin/csmock' '-r' 'fedora-rawhide-x86_64' '-t' 'gcc,cppcheck,clippy,shellcheck,unicontrol' '-o' '/tmp/tmpwiice9v_/lvm2-2.03.34-2.fc43.tar.xz' '--gcc-analyze' '--unicontrol-notests' '--unicontrol-bidi-only' '--install' 'pam' '--gcc-analyzer-bin=/usr/bin/gcc' '/tmp/tmpwiice9v_/lvm2-2.03.34-2.fc43.src.rpm' |
| tool-version | csmock-3.8.3.20251215.161544.g62de9a5-1.el9 |