nmh-workers
[Top] [All Lists]

Re: [Nmh-workers] sbr/fmt_scan.c: cpstripped(): assert(w >= 0) Failure.

2017-04-24 20:02:34
Ralph wrote:

80a9e99f7078199500d2d53c8d77d1b92af06fbc added an assert(3) as part of
the -width-overflow fix for Valdis's email.

Right.  If w < 0, bad things happen in the code just following.  If
w can indeed be negative there, maybe that code block should be simply
skipped.

any problems, in C or en_GB.utf8 locale, but it seems quite possible to
me that the wcwidth() of a `mbtowc() < 0' could be -1, as above?

wcwidth() should be negative only if wide_char is non-printable.
The code checks if iswcntrl() or iswspace(), and if so, skips the
assert and output.  If it is a wide control character, then it's not
printable, right?

David

_______________________________________________
Nmh-workers mailing list
Nmh-workers(_at_)nongnu(_dot_)org
https://lists.nongnu.org/mailman/listinfo/nmh-workers

<Prev in Thread] Current Thread [Next in Thread>