This is the mail archive of the
gdb-patches@sourceware.org
mailing list for the GDB project.
Re: [RFC 2/6] Avoid missing char before incomplete sequence in wchar_iterate.
- From: Keith Seitz <keiths at redhat dot com>
- To: Pierre Muller <pierre dot muller at ics-cnrs dot unistra dot fr>
- Cc: "'gdb-patches'" <gdb-patches at sourceware dot org>
- Date: Mon, 30 Sep 2013 18:19:18 -0700
- Subject: Re: [RFC 2/6] Avoid missing char before incomplete sequence in wchar_iterate.
- Authentication-results: sourceware.org; auth=none
- References: <002901cebaf2$35ec65a0$a1c530e0$ at muller@ics-cnrs.unistra.fr> <002f01cebaf2$aac80410$00580c30$ at muller@ics-cnrs.unistra.fr>
On 09/26/2013 12:57 PM, Pierre Muller wrote:
If charset is set to UTF-8
p "ABCD\340"
will output
"ABC" <incomplete sequence \340>
Note the missing character 'D'.
This patch solves the issue by checking also for EINVAL
if character have been converted.
This looks okay to me, but it needs a test (and a maintainer to approve).
Keith