This was reported via github: https://github.com/hugsy/gef/issues/593, but it's a bug in GDB. Compile the following go code: ``` package main import ( "fmt" ) func main() { fmt.Printf("hi"); } ``` for x86_64. Open it in GDB 10.1 b main.main run ni 7 Now run in a python interpreter ``` current_frame = gdb.selected_frame() frame_args = gdb.FrameDecorator.FrameDecorator(current_frame).frame_args() or [] values = [x.sym.value(current_frame) for x in frame_args] # You should get a list of four values # value 1 can be converted to a string str(values[1]) # This will abort str(values[0]) ```
GNU gdb (Ubuntu 10.1-1.6ubuntu1) 10.1.90.20210103-git
I tried this and it worked for me. However I don't know Go. How exactly did you compile it?
Simply with `go build x.go`
With Fedora 36 gdb (12.1) I don't see a crash. Could you try a newer gdb? I wonder if it's been fixed. Also, FTR, I had to use the golang go (not gcc.go) to even get these values.
I can still reproduce this on GDB 12.1 from ubuntu 22.04.2 installed via apt-get. Will work to reproduce on 16.2