From: "Agovic, Sanimir" <sanimir.agovic@intel.com>
To: Pedro Alves <palves@redhat.com>
Cc: "gdb-patches@sourceware.org" <gdb-patches@sourceware.org>
Subject: RE: [PATCH] add-inferior: expand tilde in -exec FILENAME argument
Date: Thu, 28 Feb 2013 17:20:00 -0000 [thread overview]
Message-ID: <0377C58828D86C4588AEEC42FC3B85A7162A0A3C@IRSMSX102.ger.corp.intel.com> (raw)
In-Reply-To: <512F7897.5000705@redhat.com>
> -----Original Message-----
> From: Pedro Alves [mailto:palves@redhat.com]
> Sent: Thursday, February 28, 2013 04:33 PM
Thanks for your feedback.
> I assume this fixes:
>
> (gdb) add-inferior -exec ~/gdb/tests/main
> Added inferior 2
> ~/gdb/tests/main: No such file or directory.
>
> even though the file does exist.
Yes. Sorry for not being clear about the cause.
> I wondered if other similar places expand the tilde early
> or just before file open [...]
I found at least one another case:
% gdb -batch \~/gdb/tests/main # or --exec=~/gdb/tests/main
~/gdb/tests/main: No such file or directory.
Whereas:
% gdb -batch --symbols=\~/gdb/tests/main
Succeeds.
Seems like gdb relies on the shell to expand its executable name.
As an alternative approach I can expand tilde in exec_file_attach
which is what symbol_file_add and core_file_command do.
-Sanimir
Intel GmbH
Dornacher Strasse 1
85622 Feldkirchen/Muenchen, Deutschland
Sitz der Gesellschaft: Feldkirchen bei Muenchen
Geschaeftsfuehrer: Christian Lamprechter, Hannes Schwaderer, Douglas Lusk
Registergericht: Muenchen HRB 47456
Ust.-IdNr./VAT Registration No.: DE129385895
Citibank Frankfurt a.M. (BLZ 502 109 00) 600119052
next prev parent reply other threads:[~2013-02-28 17:17 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2013-02-28 15:44 Sanimir Agovic
2013-02-28 15:54 ` Pedro Alves
2013-02-28 17:20 ` Agovic, Sanimir [this message]
2013-05-30 9:25 ` Pedro Alves
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=0377C58828D86C4588AEEC42FC3B85A7162A0A3C@IRSMSX102.ger.corp.intel.com \
--to=sanimir.agovic@intel.com \
--cc=gdb-patches@sourceware.org \
--cc=palves@redhat.com \
/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