gdb: fix regression in gdb.xml/maint_print_struct.exp
authorAndrew Burgess <aburgess@redhat.com>
Fri, 17 Feb 2023 10:15:27 +0000 (10:15 +0000)
committerAndrew Burgess <aburgess@redhat.com>
Fri, 17 Feb 2023 22:29:09 +0000 (22:29 +0000)
commit733da2ced8f948b299bdd10b7ff40146095f43f9
treee8fe443b13691e50acc05237bf425f1e220d7d80
parent490ea364df8bea907b6990200912b99ce79e6a55
gdb: fix regression in gdb.xml/maint_print_struct.exp

A regression in gdb.xml/maint_print_struct.exp was introduced with
commit:

  commit 81b86eced24f905545b58aa6c27478104c364976
  Date:   Fri Jan 6 09:30:40 2023 -0700

      Do not record a rejected target description

The test relied on an invalid target description being stored within
the tdesc_info of the current inferior, the above commit stopped this
behaviour.

Update the test to check that the invalid architecture is NOT stored,
and then check printing the target description directly from the
file.

Approved-By: Tom Tromey <tromey@adacore.com>
gdb/testsuite/gdb.xml/maint_print_struct.exp