Commit d00f0868 authored by Andrew Burgess's avatar Andrew Burgess
Browse files

gdb: add missing test for completion of invalid /FMT strings

This commit:

  commit 3df8c6af
  Date:   Fri Nov 27 10:46:07 2020 +0000

      gdb: fix potentially uninitialised variable

Was pushed with no test.  Naughty!

The new test checks how GDB behaves when completing an invalid /FMT
string.

Currently GDB does no validation of the /FMT string during tab
completion, and just assumes that any /FMT string is valid and
complete when the user hits TAB. So:

  (gdb) p/@@<TAB>

Will give:

  (gdb) p/@@ <CURSOR IS HERE>

We already had a test in place for completion on a valid /FMT string,
but the above commit fixed a bug in the logic for completing invalid
/FMT strings.  Now we have a test for this too.

gdb/testsuite/ChangeLog:

	* gdb.base/completion.exp: Add a new test.
parent ed205222
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment