Check for EOF in ASCII conversions.
authorPauli <paul.dale@oracle.com>
Thu, 24 Aug 2017 00:46:31 +0000 (10:46 +1000)
committerPauli <paul.dale@oracle.com>
Thu, 24 Aug 2017 20:42:17 +0000 (06:42 +1000)
commit678c462e213c3bf479bc93e4df5899ecfd914f91
treedebe6087b1bc4e34e59073e0430216c72d16be58
parentf7d1d2a479adaaae222d88710c6ceb85706ebb0f
Check for EOF in ASCII conversions.

The C standard defines EOF as:

    ... an integer constant expression, with type int and a negative value...

This means a conforming implemenetation could define this as a one of the
printable characters.  This won't be a problem for ASCII.

A specific test case has been added for EOF.

Reviewed-by: Richard Levitte <levitte@openssl.org>
(Merged from https://github.com/openssl/openssl/pull/4240)
crypto/ctype.c
test/ctype_internal_test.c