diff options
author | Andrew Burgess <aburgess@redhat.com> | 2025-08-01 12:26:41 +0100 |
---|---|---|
committer | Andrew Burgess <aburgess@redhat.com> | 2025-09-23 18:40:00 +0100 |
commit | 1ff92d0903f6d660131e93f4274e0db9d42a7f25 (patch) | |
tree | 86fdcd4667b61943ce12da57687a615b155ee622 /gdb/python/python-internal.h | |
parent | ce1b10c1ab3fc6f32621f1f23cc116ee8e39d473 (diff) | |
download | binutils-1ff92d0903f6d660131e93f4274e0db9d42a7f25.zip binutils-1ff92d0903f6d660131e93f4274e0db9d42a7f25.tar.gz binutils-1ff92d0903f6d660131e93f4274e0db9d42a7f25.tar.bz2 |
gdbserver: better handling for missing argument values
By passing ':' within the optstring to getopt_long, the getopt_long
call will now return ':' for missing value errors and '?' for unknown
argument errors, rather than returning '?' for all error types.
We can now print a different error message for missing argument
values. For example:
$ gdbserver --debug-file :54321 /tmp/hello
Missing argument value for: --debug-file
Compared to:
$ gdbserver --unknown :54321 ~/tmp/hello.x
Unknown argument: --unknown
Current HEAD gdbserver treats every error as the 'Unknown argument'
error.
While I was messing with the code that prints these error messages,
I've wrapped then with _(...) to allow for internationalisation.
Approved-By: Tom Tromey <tom@tromey.com>
Diffstat (limited to 'gdb/python/python-internal.h')
0 files changed, 0 insertions, 0 deletions