From: Jan Kratochvil <jan.kratochvil@redhat.com>
To: gdb-patches@sourceware.org
Subject: [patch] GDB regression for starting on r/o filesystem
Date: Thu, 24 Jun 2010 17:30:00 -0000 [thread overview]
Message-ID: <20100624172959.GA10631@host0.dyn.jankratochvil.net> (raw)
Hi,
currently if you have readonly/broken/full /tmp GDB will fail to start:
Cannot create temporary file in ./: Read-only file system
due to:
#0 raise () from /lib64/libc.so.6
#1 abort () from /lib64/libc.so.6
#2 make_temp_file (suffix="") at ./make-temp-file.c:205
#3 temp_file (obj=, flags=10, name=) at ./pex-common.c:109
#4 pex_run_in_environment (obj=, flags=10, executable="iconv", argv=, env=, orig_outname=, errname=, err=) at ./pex-common.c:232
#5 find_charset_names () at charset.c:803
#6 _initialize_charset () at charset.c:915
#7 initialize_all_files () at init.c:380
#8 gdb_init (argv0="/root/gdb-clean") at top.c:1670
#9 captured_main (data=) at ./main.c:657
#10 catch_errors (func=<captured_main>, func_args=, errstring="", mask=6) at exceptions.c:518
#11 gdb_main (args=) at ./main.c:945
#12 main (argc=1, argv=) at gdb.c:34
Tom suggested PEX_USE_PIPES at
https://bugzilla.redhat.com/show_bug.cgi?id=602644
@item PEX_USE_PIPES
Use pipes for communication between processes, if possible.
I see ser-mingw.c is already using it:
ps->pex = pex_init (PEX_USE_PIPES, "target remote pipe", NULL);
It should be safe across platforms:
/* DJGPP does not support pipes. */
flags &= ~ PEX_USE_PIPES;
And it starts to start on readonly filesystem again.
No regressions on {x86_64,x86_64-m32,i686}-fedora13-linux-gnu.
Thanks,
Jan
2010-06-24 Jan Kratochvil <jan.kratochvil@redhat.com>
Tom Tromey <tromey@redhat.com>
Fix GDB startup on readonly filesystem.
* charset.c (find_charset_names): Use PEX_USE_PIPES for pex_init.
--- a/gdb/charset.c
+++ b/gdb/charset.c
@@ -794,7 +794,7 @@ find_charset_names (void)
set_in_environ (iconv_env, "LANGUAGE", "C");
set_in_environ (iconv_env, "LC_ALL", "C");
- child = pex_init (0, "iconv", NULL);
+ child = pex_init (PEX_USE_PIPES, "iconv", NULL);
args[0] = "iconv";
args[1] = "-l";
next reply other threads:[~2010-06-24 17:30 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2010-06-24 17:30 Jan Kratochvil [this message]
2010-06-24 17:54 ` Tom Tromey
2010-06-24 18:24 ` Jan Kratochvil
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=20100624172959.GA10631@host0.dyn.jankratochvil.net \
--to=jan.kratochvil@redhat.com \
--cc=gdb-patches@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