[PATCH v2][makedumpfile 04/14] dwarf_info: Fix a infinite recursion bug for rust symbols

Tao Liu ltao at redhat.com
Mon Oct 20 15:24:00 PDT 2025


There is an infinite recursion bug noticed in rust symbols. The root cause is
unclear to me. This patch will avoid the bug by skip the rust
CompileUnits, since currently we don't need to deal with rust symbols.

Signed-off-by: Tao Liu <ltao at redhat.com>
Suggested-by: Kazuhito Hagio <k-hagio-ab at nec.com>
---
 dwarf_info.c | 7 +++++++
 1 file changed, 7 insertions(+)

diff --git a/dwarf_info.c b/dwarf_info.c
index a3a2fd6..14cf7ca 100644
--- a/dwarf_info.c
+++ b/dwarf_info.c
@@ -1007,6 +1007,13 @@ get_debug_info(void)
 			ERRMSG("Can't get CU die.\n");
 			goto out;
 		}
+
+		/* NOTE: currently Rust is not supported. */
+		if (dwarf_srclang(&cu_die) == DW_LANG_Rust) {
+			off = next_off;
+			continue;
+		}
+
 		search_die_tree(&cu_die, &found);
 		if (found)
 			break;
-- 
2.47.0




More information about the kexec mailing list