2003-02-02 Andrew Cagney <ac131313@redhat.com>

* frame.h: Note that namelen can be negative.
	* frame.c (frame_map_name_to_regnum): When LEN is negative, use
	NAME's length.

	* NEWS: Mention that the d10v's `regs' command is deprecated.
	* d10v-tdep.c (d10v_gdbarch_init): Set print_registers_info.
	(d10v_print_registers_info): New function.
	(show_regs): Call d10v_print_registers_info.
	(_initialize_d10v_tdep): Mark "show regs" command as deprecated.
This commit is contained in:
Andrew Cagney 2003-02-02 18:53:22 +00:00
parent 6a3fe0a431
commit 5f601589e1
5 changed files with 99 additions and 50 deletions

View file

@ -385,6 +385,9 @@ frame_map_name_to_regnum (const char *name, int len)
{
int i;
if (len < 0)
len = strlen (name);
/* Search register name space. */
for (i = 0; i < NUM_REGS + NUM_PSEUDO_REGS; i++)
if (REGISTER_NAME (i) && len == strlen (REGISTER_NAME (i))