deepin-util-dfm-1.3.3-1.fc42

List of Findings

Error: GCC_ANALYZER_WARNING (CWE-476): [#def1]
deepin-util-dfm-1.3.3-build/util-dfm-1.3.3/src/dfm-burn/3rdparty/udfclient/vfs_dirhash.c: scope_hint: In function ‘dirhash_get’
deepin-util-dfm-1.3.3-build/util-dfm-1.3.3/src/dfm-burn/3rdparty/udfclient/queue.h:481:32: warning[-Wanalyzer-null-dereference]: dereference of NULL ‘0’
deepin-util-dfm-1.3.3-build/util-dfm-1.3.3/src/dfm-burn/3rdparty/udfclient/vfs_dirhash.c:242:17: note: in expansion of macro ‘TAILQ_REMOVE’
deepin-util-dfm-1.3.3-build/util-dfm-1.3.3/src/dfm-burn/3rdparty/udfclient/vfs_dirhash.c:42: included_from: Included from here.
deepin-util-dfm-1.3.3-build/util-dfm-1.3.3/src/dfm-burn/3rdparty/udfclient/vfs_dirhash.c:242:17: note: in expansion of macro ‘TAILQ_REMOVE’
deepin-util-dfm-1.3.3-build/util-dfm-1.3.3/src/dfm-burn/3rdparty/udfclient/vfs_dirhash.c:242:17: note: in expansion of macro ‘TAILQ_REMOVE’
deepin-util-dfm-1.3.3-build/util-dfm-1.3.3/src/dfm-burn/3rdparty/udfclient/vfs_dirhash.c:242:17: note: in expansion of macro ‘TAILQ_REMOVE’
deepin-util-dfm-1.3.3-build/util-dfm-1.3.3/src/dfm-burn/3rdparty/udfclient/vfs_dirhash.c:242:17: note: in expansion of macro ‘TAILQ_REMOVE’
deepin-util-dfm-1.3.3-build/util-dfm-1.3.3/src/dfm-burn/3rdparty/udfclient/vfs_dirhash.c:242:17: note: in expansion of macro ‘TAILQ_REMOVE’
deepin-util-dfm-1.3.3-build/util-dfm-1.3.3/src/dfm-burn/3rdparty/udfclient/vfs_dirhash.c:242:17: note: in expansion of macro ‘TAILQ_REMOVE’
deepin-util-dfm-1.3.3-build/util-dfm-1.3.3/src/dfm-burn/3rdparty/udfclient/vfs_dirhash.c:242:17: note: in expansion of macro ‘TAILQ_REMOVE’
#  479|   	else								\
#  480|   		(head)->tqh_last = (elm)->field.tqe_prev;		\
#  481|-> 	*(elm)->field.tqe_prev = (elm)->field.tqe_next;			\
#  482|   	QUEUEDEBUG_TAILQ_POSTREMOVE((elm), field);			\
#  483|   } while (/*CONSTCOND*/0)

Error: COMPILER_WARNING (CWE-563): [#def2]
deepin-util-dfm-1.3.3-build/util-dfm-1.3.3/src/dfm-burn/3rdparty/udfclient/udf.c: scope_hint: In function ‘udf_to_unix_name’
deepin-util-dfm-1.3.3-build/util-dfm-1.3.3/src/dfm-burn/3rdparty/udfclient/udf.c:180:19: warning[-Wunused-but-set-variable]: variable ‘outchp’ set but not used
#  180 |     uint8_t      *outchp;
#      |                   ^~~~~~
#  178|   void udf_to_unix_name(char *result, char *id, int len, struct charspec *chsp) {
#  179|       uint16_t  raw_name[1024], unix_name[1024];
#  180|->     uint8_t	 *outchp;
#  181|       int       ucode_chars;
#  182|   

Error: COMPILER_WARNING (CWE-563): [#def3]
deepin-util-dfm-1.3.3-build/util-dfm-1.3.3/src/dfm-burn/3rdparty/udfclient/udf.c: scope_hint: In function ‘udf_node_get_fileinfo’
deepin-util-dfm-1.3.3-build/util-dfm-1.3.3/src/dfm-burn/3rdparty/udfclient/udf.c:849:43: warning[-Wunused-but-set-variable]: variable ‘ctime’ set but not used
#  849 |     struct timestamp     *atime, *mtime, *ctime, *attrtime;
#      |                                           ^~~~~
#  847|       struct file_entry    *file_entry;
#  848|       struct extfile_entry *extfile_entry;
#  849|->     struct timestamp     *atime, *mtime, *ctime, *attrtime;
#  850|       uint64_t inf_len, unique_id;
#  851|       uint32_t uid, gid, udf_perm;

Error: COMPILER_WARNING (CWE-465): [#def4]
deepin-util-dfm-1.3.3-build/util-dfm-1.3.3/src/dfm-burn/3rdparty/udfclient/udf.c: scope_hint: In function ‘udf_writeout_udf_node’
deepin-util-dfm-1.3.3-build/util-dfm-1.3.3/src/dfm-burn/3rdparty/udfclient/udf.c:1826:27: warning[-Waddress-of-packed-member]: taking address of packed member of ‘struct file_entry’ may result in an unaligned pointer value
# 1824|                   pos  = &fe->data[0] + udf_rw32(fe->l_ea);
# 1825|                   rest = dscr_entry->len - sizeof(struct file_entry) - udf_rw32(fe->l_ea);
# 1826|->                 l_adptr = &fe->l_ad;
# 1827|                   break;
# 1828|               case TAGID_EXTFENTRY      :

Error: COMPILER_WARNING (CWE-465): [#def5]
deepin-util-dfm-1.3.3-build/util-dfm-1.3.3/src/dfm-burn/3rdparty/udfclient/udf.c:1832:27: warning[-Waddress-of-packed-member]: taking address of packed member of ‘struct extfile_entry’ may result in an unaligned pointer value
# 1830|                   pos  = &efe->data[0] + udf_rw32(efe->l_ea);
# 1831|                   rest = dscr_entry->len - sizeof(struct extfile_entry) - udf_rw32(efe->l_ea);
# 1832|->                 l_adptr = &efe->l_ad;
# 1833|                   break;
# 1834|               case TAGID_ALLOCEXTENT    :

Error: COMPILER_WARNING (CWE-465): [#def6]
deepin-util-dfm-1.3.3-build/util-dfm-1.3.3/src/dfm-burn/3rdparty/udfclient/udf.c:1838:27: warning[-Waddress-of-packed-member]: taking address of packed member of ‘struct alloc_ext_entry’ may result in an unaligned pointer value
# 1836|                   pos  = &aee->data[0];
# 1837|                   rest = dscr_entry->len - sizeof(struct alloc_ext_entry);
# 1838|->                 l_adptr = &aee->l_ad;
# 1839|                   break;
# 1840|               case TAGID_INDIRECTENTRY :

Error: COMPILER_WARNING (CWE-465): [#def7]
deepin-util-dfm-1.3.3-build/util-dfm-1.3.3/src/dfm-burn/3rdparty/udfclient/udf.c: scope_hint: In function ‘udf_proc_logvol_integrity’
deepin-util-dfm-1.3.3-build/util-dfm-1.3.3/src/dfm-burn/3rdparty/udfclient/udf.c:2956:22: warning[-Waddress-of-packed-member]: taking address of packed member of ‘struct logvol_int_desc’ may result in an unaligned pointer value
# 2954|   
# 2955|       /* init start positions */
# 2956|->     free_space_pos = &new_lvid->tables[0];
# 2957|       size_pos       = &new_lvid->tables[udf_log_vol->num_part_mappings];
# 2958|   

Error: COMPILER_WARNING (CWE-465): [#def8]
deepin-util-dfm-1.3.3-build/util-dfm-1.3.3/src/dfm-burn/3rdparty/udfclient/udf.c:2957:22: warning[-Waddress-of-packed-member]: taking address of packed member of ‘struct logvol_int_desc’ may result in an unaligned pointer value
# 2955|       /* init start positions */
# 2956|       free_space_pos = &new_lvid->tables[0];
# 2957|->     size_pos       = &new_lvid->tables[udf_log_vol->num_part_mappings];
# 2958|   
# 2959|       /* init counters */

Error: CPPCHECK_WARNING (CWE-457): [#def9]
deepin-util-dfm-1.3.3-build/util-dfm-1.3.3/src/dfm-burn/3rdparty/udfclient/udf.c:3048: warning[uninitvar]: Uninitialized variables: dscr.tag, dscr.avdp, dscr.vdp, dscr.pvd, dscr.lvd, dscr.usd, dscr.lvid, dscr.ivd, dscr.pd, dscr.fsd, dscr.fid, dscr.fe, dscr.efe, dscr.eahd, dscr.inde, dscr.aee, dscr.spt, dscr.sbd, dscr.sed
# 3046|       }
# 3047|       /* free dangling descriptor */
# 3048|->     if (dscr) free(dscr);
# 3049|   
# 3050|       /* either an error has occured or we have processed all descriptors */

Error: CPPCHECK_WARNING (CWE-457): [#def10]
deepin-util-dfm-1.3.3-build/util-dfm-1.3.3/src/dfm-burn/3rdparty/udfclient/udf.c:4545: warning[uninitvar]: Uninitialized variables: dscr.tag, dscr.avdp, dscr.vdp, dscr.pvd, dscr.lvd, dscr.usd, dscr.lvid, dscr.ivd, dscr.pd, dscr.fsd, dscr.fid, dscr.fe, dscr.efe, dscr.eahd, dscr.inde, dscr.aee, dscr.spt, dscr.sbd, dscr.sed
# 4543|           dscr = NULL;
# 4544|       }
# 4545|->     if (dscr) free(dscr);
# 4546|   
# 4547|       if ((!lvid_sector) || (length == 0)) {

Error: COMPILER_WARNING (CWE-465): [#def11]
deepin-util-dfm-1.3.3-build/util-dfm-1.3.3/src/dfm-burn/3rdparty/udfclient/udf.c: scope_hint: In function ‘udf_writeout_LVID’
deepin-util-dfm-1.3.3-build/util-dfm-1.3.3/src/dfm-burn/3rdparty/udfclient/udf.c:4569:22: warning[-Waddress-of-packed-member]: taking address of packed member of ‘struct logvol_int_desc’ may result in an unaligned pointer value
# 4567|       /* calculate and fill in free space */
# 4568|       intdesc->num_part = udf_rw32(udf_log_vol->num_part_mappings);
# 4569|->     free_space_pos = &intdesc->tables[0];
# 4570|       size_pos       = &intdesc->tables[udf_log_vol->num_part_mappings];
# 4571|       SLIST_FOREACH(part_mapping, &udf_log_vol->part_mappings, next_mapping) {

Error: COMPILER_WARNING (CWE-465): [#def12]
deepin-util-dfm-1.3.3-build/util-dfm-1.3.3/src/dfm-burn/3rdparty/udfclient/udf.c:4570:22: warning[-Waddress-of-packed-member]: taking address of packed member of ‘struct logvol_int_desc’ may result in an unaligned pointer value
# 4568|       intdesc->num_part = udf_rw32(udf_log_vol->num_part_mappings);
# 4569|       free_space_pos = &intdesc->tables[0];
# 4570|->     size_pos       = &intdesc->tables[udf_log_vol->num_part_mappings];
# 4571|       SLIST_FOREACH(part_mapping, &udf_log_vol->part_mappings, next_mapping) {
# 4572|           part_num = part_mapping->udf_virt_part_num;

Error: GCC_ANALYZER_WARNING (CWE-476): [#def13]
deepin-util-dfm-1.3.3-build/util-dfm-1.3.3/src/dfm-burn/3rdparty/udfclient/udf_discop.c: scope_hint: In function ‘udf_write_physical_sectors’
deepin-util-dfm-1.3.3-build/util-dfm-1.3.3/src/dfm-burn/3rdparty/udfclient/udf_discop.c:1378:39: warning[-Wanalyzer-possible-null-dereference]: dereference of possibly-NULL ‘buffer’
deepin-util-dfm-1.3.3-build/util-dfm-1.3.3/src/dfm-burn/3rdparty/udfclient/udf_discop.c:41: included_from: Included from here.
# 1376|   			lb = source[pos  ];
# 1377|   			hb = source[pos+1];
# 1378|-> 			buffer[pos  ] = hb;
# 1379|   			buffer[pos+1] = lb;
# 1380|   			pos += 2;

Error: CPPCHECK_WARNING (CWE-758): [#def14]
deepin-util-dfm-1.3.3-build/util-dfm-1.3.3/src/dfm-burn/3rdparty/udfclient/udf_readwrite.c:271: error[shiftTooManyBitsSigned]: Shifting signed 32-bit value by 31 bits is undefined behaviour
#  269|   
#  270|   			for (cache_diff = 0; cache_diff < UDF_READWRITE_LINE_LENGTH; cache_diff++) {
#  271|-> 				bit = (1 << cache_diff);
#  272|   				if ((udf_session->cache_line_w_present & bit) == 0) {
#  273|   					from = udf_session->cache_line_read  + cache_diff * sector_size;

Error: CPPCHECK_WARNING (CWE-758): [#def15]
deepin-util-dfm-1.3.3-build/util-dfm-1.3.3/src/dfm-burn/3rdparty/udfclient/udf_readwrite.c:332: error[shiftTooManyBitsSigned]: Shifting signed 32-bit value by 31 bits is undefined behaviour
#  330|   		/* ABORT/ROLLBACK */
#  331|   		for (cache_diff = 0; cache_diff < UDF_READWRITE_LINE_LENGTH; cache_diff++) {
#  332|-> 			bit = (1 << cache_diff);
#  333|   			if (error_bits & bit) {
#  334|   				from = udf_session->cache_line_write + cache_diff * sector_size;

Error: COMPILER_WARNING (CWE-252): [#def16]
deepin-util-dfm-1.3.3-build/util-dfm-1.3.3/src/dfm-burn/3rdparty/udfclient/udfclient.c: scope_hint: In function ‘udfclient_interact’
deepin-util-dfm-1.3.3-build/util-dfm-1.3.3/src/dfm-burn/3rdparty/udfclient/udfclient.c:1561:24: warning[-Wunused-result]: ignoring return value of ‘fgets’ declared with attribute ‘warn_unused_result’
# 1561 |                 (void) fgets(line, 4096, stdin);
#      |                        ^~~~~~~~~~~~~~~~~~~~~~~~
# 1559|   
# 1560|   		*line = 0;
# 1561|-> 		(void) fgets(line, 4096, stdin);
# 1562|   
# 1563|   		if ((*line == 0) && feof(stdin)) {

Error: GCC_ANALYZER_WARNING (CWE-415): [#def17]
deepin-util-dfm-1.3.3-build/util-dfm-1.3.3/src/dfm-burn/3rdparty/udfclient/vfs_dirhash.c: scope_hint: In function ‘dirhash_purge_entries.part.0’
deepin-util-dfm-1.3.3-build/util-dfm-1.3.3/src/dfm-burn/3rdparty/udfclient/vfs_dirhash.c:178:25: warning[-Wanalyzer-double-free]: double-‘free’ of ‘dirh_e’
deepin-util-dfm-1.3.3-build/util-dfm-1.3.3/src/dfm-burn/3rdparty/udfclient/vfs_dirhash.c:51: included_from: Included from here.
deepin-util-dfm-1.3.3-build/util-dfm-1.3.3/src/dfm-burn/3rdparty/udfclient/vfs_dirhash.c:176:25: note: in expansion of macro ‘LIST_REMOVE’
deepin-util-dfm-1.3.3-build/util-dfm-1.3.3/src/dfm-burn/3rdparty/udfclient/vfs_dirhash.c:176:25: note: in expansion of macro ‘LIST_REMOVE’
#  176|   			LIST_REMOVE(dirh_e, next);
#  177|   			//pool_put(&dirhash_entry_pool, dirh_e);
#  178|-> 			free(dirh_e);
#  179|   			dirh_e = LIST_FIRST(&dirh->entries[hashline]);
#  180|   		}

Error: GCC_ANALYZER_WARNING (CWE-415): [#def18]
deepin-util-dfm-1.3.3-build/util-dfm-1.3.3/src/dfm-burn/3rdparty/udfclient/vfs_dirhash.c:186:17: warning[-Wanalyzer-double-free]: double-‘free’ of ‘dirh_e’
deepin-util-dfm-1.3.3-build/util-dfm-1.3.3/src/dfm-burn/3rdparty/udfclient/vfs_dirhash.c:184:17: note: in expansion of macro ‘LIST_REMOVE’
deepin-util-dfm-1.3.3-build/util-dfm-1.3.3/src/dfm-burn/3rdparty/udfclient/vfs_dirhash.c:184:17: note: in expansion of macro ‘LIST_REMOVE’
deepin-util-dfm-1.3.3-build/util-dfm-1.3.3/src/dfm-burn/3rdparty/udfclient/vfs_dirhash.c:184:17: note: in expansion of macro ‘LIST_REMOVE’
deepin-util-dfm-1.3.3-build/util-dfm-1.3.3/src/dfm-burn/3rdparty/udfclient/vfs_dirhash.c:184:17: note: in expansion of macro ‘LIST_REMOVE’
#  184|   		LIST_REMOVE(dirh_e, next);
#  185|   		//pool_put(&dirhash_entry_pool, dirh_e);
#  186|-> 		free(dirh_e);
#  187|   	}
#  188|   

Error: COMPILER_WARNING (CWE-252): [#def19]
deepin-util-dfm-1.3.3-build/util-dfm-1.3.3/src/dfm-burn/dfm-burn-lib/dpacketwritingcontroller.cpp: scope_hint: In constructor ‘dfmburn::DPacketWritingControllerPrivate::DPacketWritingControllerPrivate()’
deepin-util-dfm-1.3.3-build/util-dfm-1.3.3/src/dfm-burn/dfm-burn-lib/dpacketwritingcontroller.cpp:46:13: warning[-Wunused-result]: ignoring return value of ‘char* getcwd(char*, size_t)’ declared with attribute ‘warn_unused_result’
#   46 |     ::getcwd(pwd, 1024);
#      |     ~~~~~~~~^~~~~~~~~~~
#   44|   {
#   45|       char pwd[1024];
#   46|->     ::getcwd(pwd, 1024);
#   47|   
#   48|       oldLocalWoringPath = QString::fromLocal8Bit(pwd);

Error: COMPILER_WARNING (CWE-710): [#def20]
deepin-util-dfm-1.3.3-build/util-dfm-1.3.3/src/dfm-burn/dfm-burn-lib/dpacketwritingcontroller.cpp: scope_hint: In member function ‘QString dfmburn::DPacketWritingControllerPrivate::makeDiscRootPath()’
deepin-util-dfm-1.3.3-build/util-dfm-1.3.3/src/dfm-burn/dfm-burn-lib/dpacketwritingcontroller.cpp:95:49: warning[-Wwrite-strings]: ISO C++ forbids converting a string constant to ‘char*’
#   95 |     node_name = udfclient_realpath(curdir.name, "", &leaf_name);
#      |                                                 ^~
#   93|       QString path;
#   94|   
#   95|->     node_name = udfclient_realpath(curdir.name, "", &leaf_name);
#   96|   
#   97|       error = udfclient_lookup_pathname(NULL, &udf_node, node_name);

Error: COMPILER_WARNING (CWE-710): [#def21]
deepin-util-dfm-1.3.3-build/util-dfm-1.3.3/src/dfm-burn/dfm-burn-lib/dpacketwritingcontroller.cpp: scope_hint: In member function ‘bool dfmburn::DPacketWritingController::put(const QString&)’
deepin-util-dfm-1.3.3-build/util-dfm-1.3.3/src/dfm-burn/dfm-burn-lib/dpacketwritingcontroller.cpp:229:48: warning[-Wwrite-strings]: ISO C++ forbids converting a string constant to ‘char*’
#  229 |     error = udfclient_put_subtree(curdir_node, ".", fileName.toLocal8Bit().data(), ".",
#      |                                                ^~~
#  227|       totalsize = 0;
#  228|       start = dptr->getmtime();
#  229|->     error = udfclient_put_subtree(curdir_node, ".", fileName.toLocal8Bit().data(), ".",
#  230|                                     fileName.toLocal8Bit().data(), &totalsize);
#  231|       if (error) {

Error: COMPILER_WARNING (CWE-710): [#def22]
deepin-util-dfm-1.3.3-build/util-dfm-1.3.3/src/dfm-burn/dfm-burn-lib/dpacketwritingcontroller.cpp:229:84: warning[-Wwrite-strings]: ISO C++ forbids converting a string constant to ‘char*’
#  229 |     error = udfclient_put_subtree(curdir_node, ".", fileName.toLocal8Bit().data(), ".",
#      |                                                                                    ^~~
#  227|       totalsize = 0;
#  228|       start = dptr->getmtime();
#  229|->     error = udfclient_put_subtree(curdir_node, ".", fileName.toLocal8Bit().data(), ".",
#  230|                                     fileName.toLocal8Bit().data(), &totalsize);
#  231|       if (error) {

Error: COMPILER_WARNING (CWE-710): [#def23]
deepin-util-dfm-1.3.3-build/util-dfm-1.3.3/src/dfm-burn/dfm-burn-lib/dpacketwritingcontroller.cpp: scope_hint: In member function ‘bool dfmburn::DPacketWritingController::mv(const QString&, const QString&)’
deepin-util-dfm-1.3.3-build/util-dfm-1.3.3/src/dfm-burn/dfm-burn-lib/dpacketwritingcontroller.cpp:268:60: warning[-Wwrite-strings]: ISO C++ forbids converting a string constant to ‘char*’
#  268 |     old_parent_name = udfclient_realpath(rename_from_name, "..", NULL);
#      |                                                            ^~~~
#  266|       }
#  267|   
#  268|->     old_parent_name = udfclient_realpath(rename_from_name, "..", NULL);
#  269|       error = udfclient_lookup_pathname(NULL, &old_parent, old_parent_name);
#  270|       if (error || !old_parent) {

Error: COMPILER_WARNING (CWE-710): [#def24]
deepin-util-dfm-1.3.3-build/util-dfm-1.3.3/src/dfm-burn/dfm-burn-lib/dpacketwritingcontroller.cpp:283:58: warning[-Wwrite-strings]: ISO C++ forbids converting a string constant to ‘char*’
#  283 |     new_parent_name = udfclient_realpath(rename_to_name, "..", NULL);
#      |                                                          ^~~~
#  281|       rename_to_name = udfclient_realpath(curdir.name, to, &to);
#  282|       udfclient_lookup_pathname(NULL, &present, rename_to_name);
#  283|->     new_parent_name = udfclient_realpath(rename_to_name, "..", NULL);
#  284|       error = udfclient_lookup_pathname(NULL, &new_parent, new_parent_name);
#  285|       if (error || !new_parent) {

Error: COMPILER_WARNING (CWE-710): [#def25]
deepin-util-dfm-1.3.3-build/util-dfm-1.3.3/src/dfm-burn/dfm-burn-lib/dpacketwritingcontroller.cpp: scope_hint: In member function ‘bool dfmburn::DPacketWritingController::rm(const QString&)’
deepin-util-dfm-1.3.3-build/util-dfm-1.3.3/src/dfm-burn/dfm-burn-lib/dpacketwritingcontroller.cpp:332:56: warning[-Wwrite-strings]: ISO C++ forbids converting a string constant to ‘char*’
#  332 |     full_parent_name = udfclient_realpath(target_name, "..", NULL);
#      |                                                        ^~~~
#  330|       }
#  331|   
#  332|->     full_parent_name = udfclient_realpath(target_name, "..", NULL);
#  333|       error = udfclient_lookup_pathname(NULL, &parent_node, full_parent_name);
#  334|       if (error || !parent_node) {

Error: COMPILER_WARNING (CWE-477): [#def26]
deepin-util-dfm-1.3.3-build/util-dfm-1.3.3/src/dfm-io/dfm-io/dfmio_utils.cpp: scope_hint: In static member function ‘static QString dfmio::DFMUtils::devicePathFromUrl(const QUrl&)’
deepin-util-dfm-1.3.3-build/util-dfm-1.3.3/src/dfm-io/dfm-io/dfmio_utils.cpp:50:60: warning[-Wdeprecated-declarations]: ‘GUnixMountEntry* g_unix_mount_for(const char*, guint64*)’ is deprecated: Use 'g_unix_mount_entry_for' instead
#   50 |         g_autoptr(GUnixMountEntry) mount = g_unix_mount_for(g_file_get_path(gfile), nullptr);
#      |                                            ~~~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
deepin-util-dfm-1.3.3-build/util-dfm-1.3.3/src/dfm-io/dfm-io/dfmio_utils.cpp:11: included_from: Included from here.
/usr/include/gio-unix-2.0/gio/gunixmounts.h:213:18: note: declared here
#  213 | GUnixMountEntry *g_unix_mount_for                   (const char         *file_path,
#      |                  ^~~~~~~~~~~~~~~~
#   48|           return QString::fromLocal8Bit(uri);
#   49|       } else {
#   50|->         g_autoptr(GUnixMountEntry) mount = g_unix_mount_for(g_file_get_path(gfile), nullptr);
#   51|           if (mount)
#   52|               return QString::fromLocal8Bit(g_unix_mount_get_device_path(mount));

Error: COMPILER_WARNING (CWE-477): [#def27]
deepin-util-dfm-1.3.3-build/util-dfm-1.3.3/src/dfm-io/dfm-io/dfmio_utils.cpp:52:71: warning[-Wdeprecated-declarations]: ‘const char* g_unix_mount_get_device_path(GUnixMountEntry*)’ is deprecated: Use 'g_unix_mount_entry_get_device_path' instead
#   52 |             return QString::fromLocal8Bit(g_unix_mount_get_device_path(mount));
#      |                                           ~~~~~~~~~~~~~~~~~~~~~~~~~~~~^~~~~~~
/usr/include/gio-unix-2.0/gio/gunixmounts.h:98:16: note: declared here
#   98 | const char *   g_unix_mount_get_device_path         (GUnixMountEntry    *mount_entry);
#      |                ^~~~~~~~~~~~~~~~~~~~~~~~~~~~
#   50|           g_autoptr(GUnixMountEntry) mount = g_unix_mount_for(g_file_get_path(gfile), nullptr);
#   51|           if (mount)
#   52|->             return QString::fromLocal8Bit(g_unix_mount_get_device_path(mount));
#   53|       }
#   54|       return QString();

Error: COMPILER_WARNING (CWE-477): [#def28]
deepin-util-dfm-1.3.3-build/util-dfm-1.3.3/src/dfm-io/dfm-io/dfmio_utils.cpp: scope_hint: In static member function ‘static QString dfmio::DFMUtils::deviceNameFromUrl(const QUrl&)’
deepin-util-dfm-1.3.3-build/util-dfm-1.3.3/src/dfm-io/dfm-io/dfmio_utils.cpp:63:56: warning[-Wdeprecated-declarations]: ‘GUnixMountEntry* g_unix_mount_for(const char*, guint64*)’ is deprecated: Use 'g_unix_mount_entry_for' instead
#   63 |     g_autoptr(GUnixMountEntry) mount = g_unix_mount_for(g_file_peek_path(gfile), nullptr);
#      |                                        ~~~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
/usr/include/gio-unix-2.0/gio/gunixmounts.h:213:18: note: declared here
#  213 | GUnixMountEntry *g_unix_mount_for                   (const char         *file_path,
#      |                  ^~~~~~~~~~~~~~~~
#   61|   
#   62|       g_autoptr(GFile) gfile = g_file_new_for_uri(url.toString().toStdString().c_str());
#   63|->     g_autoptr(GUnixMountEntry) mount = g_unix_mount_for(g_file_peek_path(gfile), nullptr);
#   64|       if (mount)
#   65|           return QString::fromLocal8Bit(g_unix_mount_get_device_path(mount));

Error: COMPILER_WARNING (CWE-477): [#def29]
deepin-util-dfm-1.3.3-build/util-dfm-1.3.3/src/dfm-io/dfm-io/dfmio_utils.cpp:65:67: warning[-Wdeprecated-declarations]: ‘const char* g_unix_mount_get_device_path(GUnixMountEntry*)’ is deprecated: Use 'g_unix_mount_entry_get_device_path' instead
#   65 |         return QString::fromLocal8Bit(g_unix_mount_get_device_path(mount));
#      |                                       ~~~~~~~~~~~~~~~~~~~~~~~~~~~~^~~~~~~
/usr/include/gio-unix-2.0/gio/gunixmounts.h:98:16: note: declared here
#   98 | const char *   g_unix_mount_get_device_path         (GUnixMountEntry    *mount_entry);
#      |                ^~~~~~~~~~~~~~~~~~~~~~~~~~~~
#   63|       g_autoptr(GUnixMountEntry) mount = g_unix_mount_for(g_file_peek_path(gfile), nullptr);
#   64|       if (mount)
#   65|->         return QString::fromLocal8Bit(g_unix_mount_get_device_path(mount));
#   66|       return QString();
#   67|   }

Error: COMPILER_WARNING (CWE-477): [#def30]
deepin-util-dfm-1.3.3-build/util-dfm-1.3.3/src/dfm-io/dfm-io/dfmio_utils.cpp: scope_hint: In static member function ‘static QString dfmio::DFMUtils::fsTypeFromUrl(const QUrl&)’
deepin-util-dfm-1.3.3-build/util-dfm-1.3.3/src/dfm-io/dfm-io/dfmio_utils.cpp:78:56: warning[-Wdeprecated-declarations]: ‘GUnixMountEntry* g_unix_mount_for(const char*, guint64*)’ is deprecated: Use 'g_unix_mount_entry_for' instead
#   78 |     g_autoptr(GUnixMountEntry) mount = g_unix_mount_for(path, nullptr);
#      |                                        ~~~~~~~~~~~~~~~~^~~~~~~~~~~~~~~
/usr/include/gio-unix-2.0/gio/gunixmounts.h:213:18: note: declared here
#  213 | GUnixMountEntry *g_unix_mount_for                   (const char         *file_path,
#      |                  ^~~~~~~~~~~~~~~~
#   76|       if (!path)
#   77|           return QString();
#   78|->     g_autoptr(GUnixMountEntry) mount = g_unix_mount_for(path, nullptr);
#   79|       if (mount)
#   80|           return QString::fromLocal8Bit(g_unix_mount_get_fs_type(mount));

Error: COMPILER_WARNING (CWE-477): [#def31]
deepin-util-dfm-1.3.3-build/util-dfm-1.3.3/src/dfm-io/dfm-io/dfmio_utils.cpp:80:63: warning[-Wdeprecated-declarations]: ‘const char* g_unix_mount_get_fs_type(GUnixMountEntry*)’ is deprecated: Use 'g_unix_mount_entry_get_fs_type' instead
#   80 |         return QString::fromLocal8Bit(g_unix_mount_get_fs_type(mount));
#      |                                       ~~~~~~~~~~~~~~~~~~~~~~~~^~~~~~~
/usr/include/gio-unix-2.0/gio/gunixmounts.h:108:16: note: declared here
#  108 | const char *   g_unix_mount_get_fs_type             (GUnixMountEntry    *mount_entry);
#      |                ^~~~~~~~~~~~~~~~~~~~~~~~
#   78|       g_autoptr(GUnixMountEntry) mount = g_unix_mount_for(path, nullptr);
#   79|       if (mount)
#   80|->         return QString::fromLocal8Bit(g_unix_mount_get_fs_type(mount));
#   81|       return QString();
#   82|   }

Error: COMPILER_WARNING (CWE-477): [#def32]
deepin-util-dfm-1.3.3-build/util-dfm-1.3.3/src/dfm-io/dfm-io/dfmio_utils.cpp: scope_hint: In static member function ‘static QString dfmio::DFMUtils::mountPathFromUrl(const QUrl&)’
deepin-util-dfm-1.3.3-build/util-dfm-1.3.3/src/dfm-io/dfm-io/dfmio_utils.cpp:93:56: warning[-Wdeprecated-declarations]: ‘GUnixMountEntry* g_unix_mount_for(const char*, guint64*)’ is deprecated: Use 'g_unix_mount_entry_for' instead
#   93 |     g_autoptr(GUnixMountEntry) mount = g_unix_mount_for(path, nullptr);
#      |                                        ~~~~~~~~~~~~~~~~^~~~~~~~~~~~~~~
/usr/include/gio-unix-2.0/gio/gunixmounts.h:213:18: note: declared here
#  213 | GUnixMountEntry *g_unix_mount_for                   (const char         *file_path,
#      |                  ^~~~~~~~~~~~~~~~
#   91|       if (!path)
#   92|           return QString();
#   93|->     g_autoptr(GUnixMountEntry) mount = g_unix_mount_for(path, nullptr);
#   94|       if (mount)
#   95|           return QString::fromLocal8Bit(g_unix_mount_get_mount_path(mount));

Error: COMPILER_WARNING (CWE-477): [#def33]
deepin-util-dfm-1.3.3-build/util-dfm-1.3.3/src/dfm-io/dfm-io/dfmio_utils.cpp:95:66: warning[-Wdeprecated-declarations]: ‘const char* g_unix_mount_get_mount_path(GUnixMountEntry*)’ is deprecated: Use 'g_unix_mount_entry_get_mount_path' instead
#   95 |         return QString::fromLocal8Bit(g_unix_mount_get_mount_path(mount));
#      |                                       ~~~~~~~~~~~~~~~~~~~~~~~~~~~^~~~~~~
/usr/include/gio-unix-2.0/gio/gunixmounts.h:93:16: note: declared here
#   93 | const char *   g_unix_mount_get_mount_path          (GUnixMountEntry    *mount_entry);
#      |                ^~~~~~~~~~~~~~~~~~~~~~~~~~~
#   93|       g_autoptr(GUnixMountEntry) mount = g_unix_mount_for(path, nullptr);
#   94|       if (mount)
#   95|->         return QString::fromLocal8Bit(g_unix_mount_get_mount_path(mount));
#   96|       return QString();
#   97|   }

Error: COMPILER_WARNING (CWE-477): [#def34]
deepin-util-dfm-1.3.3-build/util-dfm-1.3.3/src/dfm-io/dfm-io/dfmio_utils.cpp: scope_hint: In static member function ‘static bool dfmio::DFMUtils::supportTrash(const QUrl&)’
deepin-util-dfm-1.3.3-build/util-dfm-1.3.3/src/dfm-io/dfm-io/dfmio_utils.cpp:330:56: warning[-Wdeprecated-declarations]: ‘GUnixMountEntry* g_unix_mount_for(const char*, guint64*)’ is deprecated: Use 'g_unix_mount_entry_for' instead
#  330 |     g_autoptr(GUnixMountEntry) mount = g_unix_mount_for(path1, nullptr);
#      |                                        ~~~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~
/usr/include/gio-unix-2.0/gio/gunixmounts.h:213:18: note: declared here
#  213 | GUnixMountEntry *g_unix_mount_for                   (const char         *file_path,
#      |                  ^~~~~~~~~~~~~~~~
#  328|       if (!path1)
#  329|           return false;
#  330|->     g_autoptr(GUnixMountEntry) mount = g_unix_mount_for(path1, nullptr);
#  331|       if (mount == nullptr || g_unix_mount_is_system_internal (mount))
#  332|           return false;

Error: COMPILER_WARNING (CWE-477): [#def35]
deepin-util-dfm-1.3.3-build/util-dfm-1.3.3/src/dfm-io/dfm-io/dfmio_utils.cpp:331:61: warning[-Wdeprecated-declarations]: ‘gboolean g_unix_mount_is_system_internal(GUnixMountEntry*)’ is deprecated: Use 'g_unix_mount_entry_is_system_internal' instead
#  331 |     if (mount == nullptr || g_unix_mount_is_system_internal (mount))
#      |                             ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^~~~~~~
/usr/include/gio-unix-2.0/gio/gunixmounts.h:123:16: note: declared here
#  123 | gboolean       g_unix_mount_is_system_internal      (GUnixMountEntry    *mount_entry);
#      |                ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
#  329|           return false;
#  330|       g_autoptr(GUnixMountEntry) mount = g_unix_mount_for(path1, nullptr);
#  331|->     if (mount == nullptr || g_unix_mount_is_system_internal (mount))
#  332|           return false;
#  333|   

Error: COMPILER_WARNING (CWE-477): [#def36]
deepin-util-dfm-1.3.3-build/util-dfm-1.3.3/src/dfm-io/dfm-io/utils/dlocalhelper.cpp:696:51: warning[-Wdeprecated-declarations]: ‘QStringList QString::split(QChar, SplitBehavior, Qt::CaseSensitivity) const’ is deprecated: Use split(QChar sep, Qt::SplitBehavior ...) variant instead
#  696 |             const QStringList strs { dataStr.split('\n', QString::SkipEmptyParts) };
#      |                                      ~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
/usr/include/qt5/QtCore/qstring.h:612:17: note: declared here
#  612 |     QStringList split(QChar sep, SplitBehavior behavior,
#      |                 ^~~~~
#  694|               return QSet<QString> { strs.begin(), strs.end() };
#  695|   #else
#  696|->             const QStringList strs { dataStr.split('\n', QString::SkipEmptyParts) };
#  697|               return QSet<QString>::fromList(strs);
#  698|   #endif

Error: COMPILER_WARNING (CWE-477): [#def37]
deepin-util-dfm-1.3.3-build/util-dfm-1.3.3/src/dfm-io/dfm-io/utils/dlocalhelper.cpp: scope_hint: In static member function ‘static QSet<QString> dfmio::DLocalHelper::hideListFromUrl(const QUrl&)’
deepin-util-dfm-1.3.3-build/util-dfm-1.3.3/src/dfm-io/dfm-io/utils/dlocalhelper.cpp:696:67: warning[-Wdeprecated-declarations]: ‘QString::SkipEmptyParts’ is deprecated
#  696 |             const QStringList strs { dataStr.split('\n', QString::SkipEmptyParts) };
#      |                                                                   ^~~~~~~~~~~~~~
/usr/include/qt5/QtCore/QString:1: included_from: Included from here.
deepin-util-dfm-1.3.3-build/util-dfm-1.3.3/include/dfm-io/dfm-io/error/en.h:8: included_from: Included from here.
deepin-util-dfm-1.3.3-build/util-dfm-1.3.3/include/dfm-io/dfm-io/error/error.h:8: included_from: Included from here.
deepin-util-dfm-1.3.3-build/util-dfm-1.3.3/include/dfm-io/dfm-io/dfileinfo.h:9: included_from: Included from here.
deepin-util-dfm-1.3.3-build/util-dfm-1.3.3/src/dfm-io/dfm-io/utils/dlocalhelper.h:9: included_from: Included from here.
deepin-util-dfm-1.3.3-build/util-dfm-1.3.3/src/dfm-io/dfm-io/utils/dlocalhelper.cpp:5: included_from: Included from here.
/usr/include/qt5/QtCore/qstring.h:602:9: note: declared here
#  602 |         SkipEmptyParts Q_DECL_ENUMERATOR_DEPRECATED
#      |         ^~~~~~~~~~~~~~
#  694|               return QSet<QString> { strs.begin(), strs.end() };
#  695|   #else
#  696|->             const QStringList strs { dataStr.split('\n', QString::SkipEmptyParts) };
#  697|               return QSet<QString>::fromList(strs);
#  698|   #endif

Error: COMPILER_WARNING (CWE-477): [#def38]
deepin-util-dfm-1.3.3-build/util-dfm-1.3.3/src/dfm-io/dfm-io/utils/dlocalhelper.cpp:697:43: warning[-Wdeprecated-declarations]: ‘static QSet<T> QSet<T>::fromList(const QList<T>&) [with T = QString]’ is deprecated: Use QSet<T>(list.begin(), list.end()) instead.
#  697 |             return QSet<QString>::fromList(strs);
#      |                    ~~~~~~~~~~~~~~~~~~~~~~~^~~~~~
/usr/include/qt5/QtCore/qdebug.h:52: included_from: Included from here.
/usr/include/qt5/QtCore/qcborcommon.h:45: included_from: Included from here.
/usr/include/qt5/QtCore/qcborvalue.h:45: included_from: Included from here.
/usr/include/qt5/QtCore/qcborarray.h:43: included_from: Included from here.
/usr/include/qt5/QtCore/QtCore:38: included_from: Included from here.
/usr/include/qt5/QtConcurrent/QtConcurrentDepends:3: included_from: Included from here.
/usr/include/qt5/QtConcurrent/QtConcurrent:3: included_from: Included from here.
deepin-util-dfm-1.3.3-build/util-dfm-1.3.3/include/dfm-io/dfm-io/dfileinfo.h:15: included_from: Included from here.
/usr/include/qt5/QtCore/qset.h:416:9: note: declared here
#  416 | QSet<T> QSet<T>::fromList(const QList<T> &list)
#      |         ^~~~~~~
#  695|   #else
#  696|               const QStringList strs { dataStr.split('\n', QString::SkipEmptyParts) };
#  697|->             return QSet<QString>::fromList(strs);
#  698|   #endif
#  699|           }

Error: COMPILER_WARNING (CWE-477): [#def39]
deepin-util-dfm-1.3.3-build/util-dfm-1.3.3/src/dfm-mount/lib/dprotocoldevice.cpp:134:43: warning[-Wdeprecated-declarations]: ‘QStringList QString::split(const QString&, SplitBehavior, Qt::CaseSensitivity) const’ is deprecated: Use split(const QString &sep, Qt::SplitBehavior ...) variant instead
#  134 |             auto iconLst = iconNames.split(" ", QString::SkipEmptyParts);
#      |                            ~~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
/usr/include/qt5/QtCore/qstring.h:606:17: note: declared here
#  606 |     QStringList split(const QString &sep, SplitBehavior behavior,
#      |                 ^~~~~
#  132|               auto iconLst = iconNames.split(" ", Qt::SkipEmptyParts);
#  133|   #else
#  134|->             auto iconLst = iconNames.split(" ", QString::SkipEmptyParts);
#  135|   #endif
#  136|               dp->deviceIcons = iconLst;

Error: COMPILER_WARNING (CWE-477): [#def40]
deepin-util-dfm-1.3.3-build/util-dfm-1.3.3/src/dfm-mount/lib/dprotocoldevice.cpp: scope_hint: In member function ‘QStringList dfmmount::DProtocolDevice::deviceIcons() const’
deepin-util-dfm-1.3.3-build/util-dfm-1.3.3/src/dfm-mount/lib/dprotocoldevice.cpp:134:58: warning[-Wdeprecated-declarations]: ‘QString::SkipEmptyParts’ is deprecated
#  134 |             auto iconLst = iconNames.split(" ", QString::SkipEmptyParts);
#      |                                                          ^~~~~~~~~~~~~~
/usr/include/qt5/QtCore/QString:1: included_from: Included from here.
deepin-util-dfm-1.3.3-build/util-dfm-1.3.3/include/dfm-mount/dfm-mount/base/dmount_global.h:8: included_from: Included from here.
deepin-util-dfm-1.3.3-build/util-dfm-1.3.3/src/dfm-mount/lib/dprotocoldevice.cpp:5: included_from: Included from here.
/usr/include/qt5/QtCore/qstring.h:602:9: note: declared here
#  602 |         SkipEmptyParts Q_DECL_ENUMERATOR_DEPRECATED
#      |         ^~~~~~~~~~~~~~
#  132|               auto iconLst = iconNames.split(" ", Qt::SkipEmptyParts);
#  133|   #else
#  134|->             auto iconLst = iconNames.split(" ", QString::SkipEmptyParts);
#  135|   #endif
#  136|               dp->deviceIcons = iconLst;

Error: COMPILER_WARNING (CWE-477): [#def41]
deepin-util-dfm-1.3.3-build/util-dfm-1.3.3/src/dfm-mount/lib/dprotocolmonitor.cpp: scope_hint: In static member function ‘static bool dfmmount::DProtocolMonitorPrivate::isNativeMount(const QString&)’
deepin-util-dfm-1.3.3-build/util-dfm-1.3.3/src/dfm-mount/lib/dprotocolmonitor.cpp:333:53: warning[-Wdeprecated-declarations]: ‘GUnixMountEntry* g_unix_mount_for(const char*, guint64*)’ is deprecated: Use 'g_unix_mount_entry_for' instead
#  333 |     GUnixMountEntry_autoptr entry = g_unix_mount_for(s.data(), nullptr);
#      |                                     ~~~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~~~
deepin-util-dfm-1.3.3-build/util-dfm-1.3.3/src/dfm-mount/lib/dprotocolmonitor.cpp:20: included_from: Included from here.
/usr/include/gio-unix-2.0/gio/gunixmounts.h:213:18: note: declared here
#  213 | GUnixMountEntry *g_unix_mount_for                   (const char         *file_path,
#      |                  ^~~~~~~~~~~~~~~~
#  331|   
#  332|       std::string s = mpt.toStdString();
#  333|->     GUnixMountEntry_autoptr entry = g_unix_mount_for(s.data(), nullptr);
#  334|       if (entry) {
#  335|           QString devPath = g_unix_mount_get_device_path(entry);

Error: COMPILER_WARNING (CWE-477): [#def42]
deepin-util-dfm-1.3.3-build/util-dfm-1.3.3/src/dfm-mount/lib/dprotocolmonitor.cpp:335:55: warning[-Wdeprecated-declarations]: ‘const char* g_unix_mount_get_device_path(GUnixMountEntry*)’ is deprecated: Use 'g_unix_mount_entry_get_device_path' instead
#  335 |         QString devPath = g_unix_mount_get_device_path(entry);
#      |                           ~~~~~~~~~~~~~~~~~~~~~~~~~~~~^~~~~~~
/usr/include/gio-unix-2.0/gio/gunixmounts.h:98:16: note: declared here
#   98 | const char *   g_unix_mount_get_device_path         (GUnixMountEntry    *mount_entry);
#      |                ^~~~~~~~~~~~~~~~~~~~~~~~~~~~
#  333|       GUnixMountEntry_autoptr entry = g_unix_mount_for(s.data(), nullptr);
#  334|       if (entry) {
#  335|->         QString devPath = g_unix_mount_get_device_path(entry);
#  336|           if (devPath.startsWith("/dev/"))
#  337|               return true;

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-156.us-west-2.compute.internal
mock-configfedora-rawhide-gcc-latest-x86_64
project-namedeepin-util-dfm-1.3.3-1.fc42
store-results-to/tmp/tmpjh_rvqrj/deepin-util-dfm-1.3.3-1.fc42.tar.xz
time-created2024-11-12 23:33:02
time-finished2024-11-12 23:35:12
toolcsmock
tool-args'/usr/bin/csmock' '-r' 'fedora-rawhide-gcc-latest-x86_64' '-t' 'clippy,cppcheck,gcc,unicontrol,shellcheck' '-o' '/tmp/tmpjh_rvqrj/deepin-util-dfm-1.3.3-1.fc42.tar.xz' '--gcc-analyze' '--unicontrol-notests' '--unicontrol-bidi-only' '--install=gcc-latest' '--gcc-analyzer-bin=/opt/gcc-latest/bin/gcc' '/tmp/tmpjh_rvqrj/deepin-util-dfm-1.3.3-1.fc42.src.rpm'
tool-versioncsmock-3.7.1.20241107.094801.gb3f0f26.pr_192-1.el9