public inbox for gdb-prs@sourceware.org
help / color / mirror / Atom feed
From: "nchatz314 at gmail dot com" <sourceware-bugzilla@sourceware.org>
To: gdb-prs@sourceware.org
Subject: [Bug cli/29223] gdb crashes with empty guile command in configuration file
Date: Sat, 04 Jun 2022 05:43:05 +0000	[thread overview]
Message-ID: <bug-29223-4717-zYVCTd9t7I@http.sourceware.org/bugzilla/> (raw)
In-Reply-To: <bug-29223-4717@http.sourceware.org/bugzilla/>

https://sourceware.org/bugzilla/show_bug.cgi?id=29223

--- Comment #3 from Nikolaos Chatzikonstantinou <nchatz314 at gmail dot com> ---
I've narrowed it down to a null dereference of ui_out->current_uiout, here is a
backtrace:

#0  ui_out::is_mi_like_p (this=0x0) at ui-out.c:820
#1  0x00000000004fdeba in execute_control_command (cmd=0xe7b640, from_tty=0) at
cli/cli-script.c:699
#2  0x00000000005f9ee3 in guile_command (arg=<optimized out>,
from_tty=<optimized out>) at /usr/include/c++/12/bits/shared_ptr_base.h:1665
#3  0x00000000004f2d55 in cmd_func (cmd=<optimized out>, args=<optimized out>,
from_tty=<optimized out>) at cli/cli-decode.c:2514
#4  0x00000000007c7aeb in execute_command (p=<optimized out>, p@entry=0xe86ad0
"guile", from_tty=0) at top.c:699
#5  0x00000000005c053d in command_handler (command=0xe86ad0 "guile") at
event-top.c:598
#6  0x00000000007c894f in read_command_file (stream=stream@entry=0xd9b5d0) at
top.c:468
#7  0x00000000004fc088 in script_from_file (stream=stream@entry=0xd9b5d0,
file=file@entry=0xe86aa0 "/home/fox/.config/gdb/gdbearlyinit") at
cli/cli-script.c:1625
#8  0x00000000004efcab in source_script_from_stream (file_to_open=0xe86af0
"/home/fox/.config/gdb/gdbearlyinit", file=0xe86aa0
"/home/fox/.config/gdb/gdbearlyinit", stream=0xd9b5d0) at cli/cli-cmds.c:715
#9  source_script_with_search (file=0xe86aa0
"/home/fox/.config/gdb/gdbearlyinit", file@entry=<error reading variable: value
has been optimized out>, from_tty=<error reading variable: value has been
optimized out>, 
    search_path=<error reading variable: value has been optimized out>) at
cli/cli-cmds.c:760
#10 0x000000000066f652 in catch_command_errors (command=<optimized out>,
arg=<optimized out>, from_tty=<optimized out>, do_bp_actions=<optimized out>)
at main.c:515
#11 0x0000000000671ba1 in captured_main_1 (context=<optimized out>) at
/usr/include/c++/12/bits/basic_string.h:234
#12 0x0000000000671feb in captured_main (data=data@entry=0x7fffffffdd70) at
main.c:1325
#13 gdb_main (args=args@entry=0x7fffffffdda0) at main.c:1350
#14 0x0000000000432d25 in main (argc=<optimized out>, argv=<optimized out>) at
gdb.c:32

-- 
You are receiving this mail because:
You are on the CC list for the bug.

  parent reply	other threads:[~2022-06-04  5:43 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-06-02 10:54 [Bug cli/29223] New: " nchatz314 at gmail dot com
2022-06-03 17:20 ` [Bug cli/29223] " tromey at sourceware dot org
2022-06-04  1:17 ` nchatz314 at gmail dot com
2022-06-04  5:43 ` nchatz314 at gmail dot com [this message]
2022-06-04 10:26 ` nchatz314 at gmail dot com
2022-06-04 16:06 ` tromey at sourceware dot org

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=bug-29223-4717-zYVCTd9t7I@http.sourceware.org/bugzilla/ \
    --to=sourceware-bugzilla@sourceware.org \
    --cc=gdb-prs@sourceware.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).