Skip Menu |
 

Download (untitled) / with headers
text/plain 27.9KiB

Message body is not shown because it is too large.

Download (untitled) / with headers
text/plain 248.7KiB

Message body is not shown because it is too large.

Subject: make check fails because high-bit chars passed isprint()
After decoding the attachments, I found that the output from
tests/asn.1/krb5_encode_test was different from the expected output in
one key way: in the ASCII dumps, characters with the high bit set were
being output instead of using "." as a placeholder for non-printing
characters.

I don't believe I have ever seen this problem, but I think it could
arise again. The behavior of isprint is influenced by the current
locale, so some of these high-bit characters could become printing
characters. Probably the right thing to do is add a test for values
under 127 (since it's an unsigned char value). Or we could use
something like 'setlocale(LC_CTYPE,"C")' to force "normal"
interpretation.
We haven't had any reports of this in a long time. Since the ASN.1 tests
do not call setlocale(), isprint() should be using C locale semantics
(per C99 section 7.11.1.1 paragraph 4, and probably similar text in C89).