This is the mail archive of the
gdb-patches@sources.redhat.com
mailing list for the GDB project.
Re: [PATCH} Minor bug fix in arch-utils.c
- To: John S Kallal <jskallal at home dot com>,Adam Mirowski <mir at solfege dot France dot Sun dot COM>
- Subject: Re: [PATCH} Minor bug fix in arch-utils.c
- From: Andrew Cagney <ac131313 at cygnus dot com>
- Date: Wed, 09 May 2001 16:23:05 -0400
- Cc: gdb-patches at sources dot redhat dot com
- References: <000701c0cea9$7b18ed80$6401a8c0@cn986452a>
> The following is a one line patch to
> end a segmentation fault when the
> command 'info architecture' is used
> on GDB running on a SUSE-7.0 Linux
> system.
>
>
> 2001-04-26 John S Kallal <jskallal@home.com>
>
> * arch-utils.c/info_architecture: Remove 2nd
> pointer list update to correctly follow
> linked list.
Yes, I've seen this patch twice now. While an obvious fix, I'm going to
check in the attached. The ``info architecture'' command can simply be
deleted.
Andrew
2001-05-09 Andrew Cagney <ac131313@redhat.com>
* arch-utils.c (initialize_current_architecture): Delete obsolete
``info architecture'' command.
*** /home/scratch/GDB/src/gdb/arch-utils.c Tue May 8 11:58:38 2001
--- arch-utils.c Wed May 9 16:17:00 2001
***************
*** 586,625 ****
show_architecture (NULL, from_tty);
}
- /* Called if the user enters ``info architecture'' without an argument. */
-
- static void
- info_architecture (char *args, int from_tty)
- {
- printf_filtered ("Available architectures are:\n");
- if (GDB_MULTI_ARCH)
- {
- const char **arches = gdbarch_printable_names ();
- const char **arch;
- for (arch = arches; *arch != NULL; arch++)
- {
- printf_filtered (" %s", *arch);
- }
- xfree (arches);
- }
- else
- {
- enum bfd_architecture a;
- for (a = bfd_arch_obscure + 1; a < bfd_arch_last; a++)
- {
- const struct bfd_arch_info *ap;
- for (ap = bfd_lookup_arch (a, 0);
- ap != NULL;
- ap = ap->next)
- {
- printf_filtered (" %s", ap->printable_name);
- ap = ap->next;
- }
- }
- }
- printf_filtered ("\n");
- }
-
/* Set the dynamic target-system-dependent parameters (architecture,
byte-order) using information found in the BFD */
--- 586,591 ----
***************
*** 759,767 ****
current setting. */
add_cmd ("architecture", class_support, show_architecture,
"Show the current target architecture", &showlist);
- c = add_cmd ("architecture", class_support, info_architecture,
- "List supported target architectures", &infolist);
- deprecate_cmd (c, "set architecture");
}
}
--- 725,730 ----