basenc: --base16: also allow lower case with --ignore-garbage

* src/basenc.c (isbase16): Also return true for lower case.
* tests/basenc/basenc.pl: Add a test case.
Reported by Paul Eggert.
This commit is contained in:
Pádraig Brady
2023-10-25 14:04:00 +01:00
parent d733f2ec26
commit 5f538c27a1
2 changed files with 4 additions and 2 deletions

View File

@@ -160,6 +160,7 @@ my @Tests =
{ERR=>"$prog: invalid input\n"}],
['b16_8', '--base16 -d', {IN=>"AB\nCD"}, {OUT=>"\xAB\xCD"}],
['b16_9', '--base16 -d', {IN=>lc ($base16_out)}, {OUT=>$base16_in}],
['b16_10', '--base16 -d -i', {IN=>lc ($base16_out)}, {OUT=>$base16_in}],