mirror of
https://github.com/espressif/binutils-gdb.git
synced 2025-06-20 01:50:24 +08:00
gdb/debuginfod-support.c: Always display debuginfod errors
Errors encountered when downloading files from debuginfod servers are not displayed if debuginfod verbosity is set to 0 (via 'set debuginfod verbose 0'). Tom recommended that these errors always be displayed, regardless of the verbosity setting [1]. Fix this. [1] https://sourceware.org/pipermail/gdb-patches/2022-March/186350.html
This commit is contained in:
@ -254,7 +254,7 @@ debuginfod_source_query (const unsigned char *build_id,
|
||||
&dname));
|
||||
debuginfod_set_user_data (c, nullptr);
|
||||
|
||||
if (debuginfod_verbose > 0 && fd.get () < 0 && fd.get () != -ENOENT)
|
||||
if (fd.get () < 0 && fd.get () != -ENOENT)
|
||||
gdb_printf (_("Download failed: %s. Continuing without source file %ps.\n"),
|
||||
safe_strerror (-fd.get ()),
|
||||
styled_string (file_name_style.style (), srcpath));
|
||||
@ -296,7 +296,7 @@ debuginfod_debuginfo_query (const unsigned char *build_id,
|
||||
&dname));
|
||||
debuginfod_set_user_data (c, nullptr);
|
||||
|
||||
if (debuginfod_verbose > 0 && fd.get () < 0 && fd.get () != -ENOENT)
|
||||
if (fd.get () < 0 && fd.get () != -ENOENT)
|
||||
gdb_printf (_("Download failed: %s. Continuing without debug info for %ps.\n"),
|
||||
safe_strerror (-fd.get ()),
|
||||
styled_string (file_name_style.style (), filename));
|
||||
@ -337,7 +337,7 @@ debuginfod_exec_query (const unsigned char *build_id,
|
||||
scoped_fd fd (debuginfod_find_executable (c, build_id, build_id_len, &dname));
|
||||
debuginfod_set_user_data (c, nullptr);
|
||||
|
||||
if (debuginfod_verbose > 0 && fd.get () < 0 && fd.get () != -ENOENT)
|
||||
if (fd.get () < 0 && fd.get () != -ENOENT)
|
||||
gdb_printf (_("Download failed: %s. " \
|
||||
"Continuing without executable for %ps.\n"),
|
||||
safe_strerror (-fd.get ()),
|
||||
|
Reference in New Issue
Block a user