This is the mail archive of the
gdb-patches@sourceware.org
mailing list for the GDB project.
Re: [patch] gdb_gcore man/help/install [+doc]
- From: Andreas Schwab <schwab at linux-m68k dot org>
- To: Jan Kratochvil <jan dot kratochvil at redhat dot com>
- Cc: gdb-patches at sourceware dot org
- Date: Mon, 25 Apr 2011 10:32:02 +0200
- Subject: Re: [patch] gdb_gcore man/help/install [+doc]
- References: <20110425074138.GA5408@host1.jankratochvil.net>
Jan Kratochvil <jan.kratochvil@redhat.com> writes:
> --- a/gdb/gdb_gcore.sh
> +++ b/gdb/gdb_gcore.sh
> @@ -22,9 +22,9 @@
> # It starts up gdb, attaches to the given PID and invokes the gcore command.
> #
>
> -if [ "$#" -eq "0" ]
> +if [ "$#" -eq "0" -o "$1" = "-h" -o "$1" = "--help" ]
> then
> - echo "usage: gcore [-o filename] pid"
> + echo "usage: gcore [-o filename] pid1 [pid2...]"
+ echo "Usage: gcore [-o FILENAME] PID..."
> exit 2
--help should exit successfully. Also, test .. -o .. should be avoided.
case $#$1 in 0|1-h|1--help) ...
Andreas.
--
Andreas Schwab, schwab@linux-m68k.org
GPG Key fingerprint = 58CA 54C7 6D53 942B 1756 01D3 44D5 214B 8276 4ED5
"And now for something completely different."