Task #119206 - fixed.err
back to task #119206download
Error: COMPILER_WARNING:
localsearch-3.11.rc/src/cli/tracker-search.c: scope_hint: In function ‘get_cursor_results’
localsearch-3.11.rc/src/cli/tracker-search.c:272:14: warning[-Wunused-but-set-variable=]: variable ‘count’ set but not used
# 272 | gint count = 0;
# | ^~~~~
# 270| {
# 271| gboolean is_tty;
# 272|-> gint count = 0;
# 273|
# 274| is_tty = tracker_term_is_tty ();
Error: COMPILER_WARNING (CWE-704):
localsearch-3.11.rc/src/common/tracker-file-utils.c: scope_hint: In function ‘tracker_path_list_filter_duplicates’
localsearch-3.11.rc/src/common/tracker-file-utils.c:442:27: warning[-Wdiscarded-qualifiers]: assignment discards ‘const’ qualifier from pointer target type
# 442 | p = strrchr (path, G_DIR_SEPARATOR);
# | ^
# 440|
# 441| if (G_LIKELY (!reset)) {
# 442|-> p = strrchr (path, G_DIR_SEPARATOR);
# 443|
# 444| /* Make sure the path doesn't have the '/' suffix. */
Error: COMPILER_WARNING (CWE-704):
localsearch-3.11.rc/src/common/tracker-file-utils.c:442:27: warning[-Wdiscarded-qualifiers]: assignment discards ‘const’ qualifier from pointer target type
# 440|
# 441| if (G_LIKELY (!reset)) {
# 442|-> p = strrchr (path, G_DIR_SEPARATOR);
# 443|
# 444| /* Make sure the path doesn't have the '/' suffix. */
Error: COMPILER_WARNING (CWE-704):
localsearch-3.11.rc/src/common/tracker-file-utils.c: scope_hint: In function ‘tracker_filename_casecmp_without_extension’
localsearch-3.11.rc/src/common/tracker-file-utils.c:743:12: warning[-Wdiscarded-qualifiers]: assignment discards ‘const’ qualifier from pointer target type
# 743 | pa = strrchr (a, '.');
# | ^
# 741| g_return_val_if_fail (b != NULL, FALSE);
# 742|
# 743|-> pa = strrchr (a, '.');
# 744| pb = strrchr (b, '.');
# 745|
Error: COMPILER_WARNING (CWE-704):
localsearch-3.11.rc/src/common/tracker-file-utils.c:743:12: warning[-Wdiscarded-qualifiers]: assignment discards ‘const’ qualifier from pointer target type
# 741| g_return_val_if_fail (b != NULL, FALSE);
# 742|
# 743|-> pa = strrchr (a, '.');
# 744| pb = strrchr (b, '.');
# 745|
Error: COMPILER_WARNING (CWE-704):
localsearch-3.11.rc/src/common/tracker-file-utils.c:744:12: warning[-Wdiscarded-qualifiers]: assignment discards ‘const’ qualifier from pointer target type
# 744 | pb = strrchr (b, '.');
# | ^
# 742|
# 743| pa = strrchr (a, '.');
# 744|-> pb = strrchr (b, '.');
# 745|
# 746| /* Did we find a "." */
Error: COMPILER_WARNING (CWE-704):
localsearch-3.11.rc/src/common/tracker-file-utils.c:744:12: warning[-Wdiscarded-qualifiers]: assignment discards ‘const’ qualifier from pointer target type
# 742|
# 743| pa = strrchr (a, '.');
# 744|-> pb = strrchr (b, '.');
# 745|
# 746| /* Did we find a "." */
Error: COMPILER_WARNING (CWE-704):
localsearch-3.11.rc/src/extractor/tracker-extract-png.c: scope_hint: In function ‘raw_profile_new’
localsearch-3.11.rc/src/extractor/tracker-extract-png.c:145:27: warning[-Wdiscarded-qualifiers]: assignment discards ‘const’ qualifier from pointer target type
# 145 | p = strchr (lut, a);
# | ^
# 143| do {
# 144| gchar a = ptr[i];
# 145|-> p = strchr (lut, a);
# 146| i++;
# 147| } while (p == 0);
Error: COMPILER_WARNING (CWE-704):
localsearch-3.11.rc/src/extractor/tracker-extract-png.c:145:27: warning[-Wdiscarded-qualifiers]: assignment discards ‘const’ qualifier from pointer target type
# 143| do {
# 144| gchar a = ptr[i];
# 145|-> p = strchr (lut, a);
# 146| i++;
# 147| } while (p == 0);
Error: COMPILER_WARNING (CWE-704):
localsearch-3.11.rc/src/extractor/tracker-extract-png.c:151:27: warning[-Wdiscarded-qualifiers]: assignment discards ‘const’ qualifier from pointer target type
# 151 | q = strchr (lut, b);
# | ^
# 149| do {
# 150| gchar b = ptr[i];
# 151|-> q = strchr (lut, b);
# 152| i++;
# 153| } while (q == 0);
Error: COMPILER_WARNING (CWE-704):
localsearch-3.11.rc/src/extractor/tracker-extract-png.c:151:27: warning[-Wdiscarded-qualifiers]: assignment discards ‘const’ qualifier from pointer target type
# 149| do {
# 150| gchar b = ptr[i];
# 151|-> q = strchr (lut, b);
# 152| i++;
# 153| } while (q == 0);
Error: COMPILER_WARNING (CWE-563):
localsearch-3.11.rc/src/extractor/utils/tracker-exif.c: scope_hint: In function ‘tracker_exif_new_from_metadata’
localsearch-3.11.rc/src/extractor/utils/tracker-exif.c:156:54: warning[-Wunused-variable]: unused variable ‘tmp_gps’
# 156 | double fnumber, lat, lon, alt, focal_length, tmp_gps;
# | ^~~~~~~
# 154| g_autofree char *tmp = NULL;
# 155| gchar buf[G_ASCII_DTOSTR_BUF_SIZE];
# 156|-> double fnumber, lat, lon, alt, focal_length, tmp_gps;
# 157| int nom, den;
# 158| glong tmp_long;
Error: COMPILER_WARNING (CWE-704):
localsearch-3.11.rc/src/extractor/utils/tracker-xmp.c: scope_hint: In function ‘div_str_dup’
localsearch-3.11.rc/src/extractor/utils/tracker-xmp.c:205:22: warning[-Wdiscarded-qualifiers]: initialization discards ‘const’ qualifier from pointer target type
# 205 | gchar *ptr = strchr (value, '/');
# | ^~~~~~
# 203| {
# 204| gchar *ret;
# 205|-> gchar *ptr = strchr (value, '/');
# 206|
# 207| if (ptr) {
Error: COMPILER_WARNING (CWE-704):
localsearch-3.11.rc/src/extractor/utils/tracker-xmp.c:205:22: warning[-Wdiscarded-qualifiers]: initialization discards ‘const’ qualifier from pointer target type
# 203| {
# 204| gchar *ret;
# 205|-> gchar *ptr = strchr (value, '/');
# 206|
# 207| if (ptr) {
Error: GCC_ANALYZER_WARNING (CWE-775):
localsearch-3.11.rc/tests/functional-tests/test-extractor-modules/malice/fs-read-trunc/fs-read-trunc.c:16:12: warning[-Wanalyzer-fd-leak]: leak of file descriptor ‘open(g_file_get_path(tracker_extract_info_get_file(info)), 512)’
localsearch-3.11.rc/tests/functional-tests/test-extractor-modules/malice/fs-read-trunc/fs-read-trunc.c:15:14: acquire_resource: opened here
localsearch-3.11.rc/tests/functional-tests/test-extractor-modules/malice/fs-read-trunc/fs-read-trunc.c:16:12: danger: ‘open(g_file_get_path(tracker_extract_info_get_file(info)), 512)’ leaks here; was opened at [(1)](sarif:/runs/0/results/0/codeFlows/0/threadFlows/0/locations/0)
# 14| /* Attempt to truncate the file */
# 15| fd = open (path, O_RDONLY | O_TRUNC);
# 16|-> if (fd >= 0)
# 17| goto fail;
# 18|
Error: GCC_ANALYZER_WARNING (CWE-775):
localsearch-3.11.rc/tests/functional-tests/test-extractor-modules/malice/fs-read/fs-read.c:15:12: warning[-Wanalyzer-fd-leak]: leak of file descriptor ‘open("/proc/cmdline", 0)’
localsearch-3.11.rc/tests/functional-tests/test-extractor-modules/malice/fs-read/fs-read.c:14:14: acquire_resource: opened here
localsearch-3.11.rc/tests/functional-tests/test-extractor-modules/malice/fs-read/fs-read.c:15:12: danger: ‘open("/proc/cmdline", 0)’ leaks here; was opened at [(1)](sarif:/runs/0/results/0/codeFlows/0/threadFlows/0/locations/0)
# 13| /* Attempt to read files from disallowed locations */
# 14| fd = open ("/proc/cmdline", O_RDONLY);
# 15|-> if (fd >= 0)
# 16| goto fail;
# 17|
Error: GCC_ANALYZER_WARNING (CWE-775):
localsearch-3.11.rc/tests/functional-tests/test-extractor-modules/malice/fs-read/fs-read.c:19:12: warning[-Wanalyzer-fd-leak]: leak of file descriptor ‘open("/etc/motd", 0)’
localsearch-3.11.rc/tests/functional-tests/test-extractor-modules/malice/fs-read/fs-read.c:15:12: branch_false: following ‘false’ branch...
localsearch-3.11.rc/tests/functional-tests/test-extractor-modules/malice/fs-read/fs-read.c:18:14: branch_false: ...to here
localsearch-3.11.rc/tests/functional-tests/test-extractor-modules/malice/fs-read/fs-read.c:18:14: acquire_resource: opened here
localsearch-3.11.rc/tests/functional-tests/test-extractor-modules/malice/fs-read/fs-read.c:19:12: danger: ‘open("/etc/motd", 0)’ leaks here; was opened at [(3)](sarif:/runs/0/results/1/codeFlows/0/threadFlows/0/locations/2)
# 17|
# 18| fd = open ("/etc/motd", O_RDONLY);
# 19|-> if (fd >= 0)
# 20| goto fail;
# 21|
Error: GCC_ANALYZER_WARNING (CWE-775):
localsearch-3.11.rc/tests/functional-tests/test-extractor-modules/malice/fs-read/fs-read.c:24:12: warning[-Wanalyzer-fd-leak]: leak of file descriptor ‘open(g_path_get_dirname(g_get_home_dir()), 65536)’
localsearch-3.11.rc/tests/functional-tests/test-extractor-modules/malice/fs-read/fs-read.c:15:12: branch_false: following ‘false’ branch...
localsearch-3.11.rc/tests/functional-tests/test-extractor-modules/malice/fs-read/fs-read.c:18:14: branch_false: ...to here
localsearch-3.11.rc/tests/functional-tests/test-extractor-modules/malice/fs-read/fs-read.c:19:12: branch_false: following ‘false’ branch...
localsearch-3.11.rc/tests/functional-tests/test-extractor-modules/malice/fs-read/fs-read.c:22:23: branch_false: ...to here
localsearch-3.11.rc/tests/functional-tests/test-extractor-modules/malice/fs-read/fs-read.c:23:14: acquire_resource: opened here
localsearch-3.11.rc/tests/functional-tests/test-extractor-modules/malice/fs-read/fs-read.c:24:12: danger: ‘open(g_path_get_dirname(g_get_home_dir()), 65536)’ leaks here; was opened at [(5)](sarif:/runs/0/results/2/codeFlows/0/threadFlows/0/locations/4)
# 22| home_parent = g_path_get_dirname (g_get_home_dir ());
# 23| fd = open (home_parent, O_RDONLY | O_DIRECTORY);
# 24|-> if (fd >= 0)
# 25| goto fail;
# 26|