From 3a674486ec3a67bbe1e1b96ed676679a1903dc83 Mon Sep 17 00:00:00 2001 From: Jan Kratochvil Date: Fri, 23 Jul 2010 21:10:55 +0000 Subject: [PATCH] gdb/ * gdb_gcore.sh (tmpfile): Remove the variable, its initialization, cleanup and generating of gdb script to it. (gdb): Use redirection from /dev/null. Use --nx. Turn off pagination and terminal size. Convert $tmpfile to a series of -ex-es. --- gdb/ChangeLog | 7 +++++++ gdb/gdb_gcore.sh | 25 +++++-------------------- 2 files changed, 12 insertions(+), 20 deletions(-) diff --git a/gdb/ChangeLog b/gdb/ChangeLog index 763e988564..e2062d82fe 100644 --- a/gdb/ChangeLog +++ b/gdb/ChangeLog @@ -1,3 +1,10 @@ +2010-07-23 Jan Kratochvil + + * gdb_gcore.sh (tmpfile): Remove the variable, its initialization, + cleanup and generating of gdb script to it. + (gdb): Use redirection from /dev/null. Use --nx. Turn off pagination + and terminal size. Convert $tmpfile to a series of -ex-es. + 2010-07-23 Keith Seitz * symtab.c (basic_lookup_transparent_type): Call pre-expand diff --git a/gdb/gdb_gcore.sh b/gdb/gdb_gcore.sh index c51199fcc4..666b8373c4 100755 --- a/gdb/gdb_gcore.sh +++ b/gdb/gdb_gcore.sh @@ -45,32 +45,17 @@ then shift; shift fi -# Create a temporary file. Use mktemp if available, but cope if it is not. -tmpfile=`mktemp ${name}.XXXXXX 2>/dev/null` || { - tmpfile=${name}.$$ - if test -e $tmpfile; then - echo "Could not create temporary file $tmpfile" - exit 1 - fi - touch $tmpfile -} -trap "rm -f $tmpfile" EXIT - # Initialise return code. rc=0 # Loop through pids for pid in $* do - # Write gdb script for pid $pid. - cat >>$tmpfile <