(gdb) file docker Reading symbols from docker...done. (gdb) tb *_start Temporary breakpoint 1 at 0x73a7b0 (gdb) run Starting program: /usr/bin/docker [...] go-lang.c:403: internal-error: go_symbol_package_name: Assertion `SYMBOL_LANGUAGE (sym) == language_go' failed. A problem internal to GDB has been detected, further debugging may prove unreliable.
The assert looks too aggressive, =>gdb_assert (SYMBOL_LANGUAGE (sym) == language_go); though go_symbol_package_name does expect a go symbol. I'd say have the caller first check for a go symbol.
I wrote the patch.
The master branch has been updated by Tom Tromey <tromey@sourceware.org>: https://sourceware.org/git/gitweb.cgi?p=binutils-gdb.git;h=e8eca7a6b602290bb3f50728432d524577ade727 commit e8eca7a6b602290bb3f50728432d524577ade727 Author: Tom Tromey <tom@tromey.com> Date: Thu Feb 16 17:52:07 2023 -0700 Fix crash in go_symbol_package_name go_symbol_package_name package name asserts that it is only passed a Go symbol, but this is not enforced by one caller. It seems simplest to just check and return early in this case. Bug: https://sourceware.org/bugzilla/show_bug.cgi?id=17876 Reviewed-By: Andrew Burgess <aburgess@redhat.com>
Fixed.