Fix strings.c endian issue and strings test
authorAlan Modra <amodra@gmail.com>
Sat, 8 Dec 2018 01:19:20 +0000 (11:49 +1030)
committerAlan Modra <amodra@gmail.com>
Sat, 8 Dec 2018 02:52:33 +0000 (13:22 +1030)
commit7ca166c9408599e64c0cd3c5d3f0d00c8fae2d9e
tree5021f0e2465f9889af033ddc284c4b0fa8562cd2
parent5aee1c38f938d4f7c9f8365fabf81e2d1f1ca051
Fix strings.c endian issue and strings test

git commit 71f5e3f7b624 obviously wasn't tested on a big-endian host,
and the test fail message resulted in tcl errors.

* strings.c (unget_part_char): New function.
(print_strings): Use unget_part_char.  Formatting.
* testsuite/binutils-all/strings.exp (test_multibyte): Don't
use square brackets in fail message.  Expect "String1\nString2".
binutils/ChangeLog
binutils/strings.c
binutils/testsuite/binutils-all/strings.exp