[Bug 377] New: Reduce compiler warnings. Use unsigned args to the ctype.h is*() macros.

Ben Lindstrom mouring at etoh.eviladmin.org
Sat Aug 3 00:20:24 EST 2002


On Fri, 2 Aug 2002, Mark D. Baushke wrote:

[..]
>
> Index: canohost.c
> ===================================================================
> RCS file: /cvs/openssh/canohost.c,v
> retrieving revision 1.30
> diff -u -p -r1.30 canohost.c
> --- canohost.c	11 Jul 2002 03:56:47 -0000	1.30
> +++ canohost.c	2 Aug 2002 14:19:16 -0000
> @@ -90,7 +90,7 @@ get_remote_hostname(int socket, int veri
>  	 * of this software).
>  	 */
>  	for (i = 0; name[i]; i++)
> -		if (isupper(name[i]))
> +		if (isupper((unsigned char)name[i]))
>  			name[i] = tolower(name[i]);
>

Umm.. why not just change 'char name[..];' to u_char name[..]?  Fix the
issue at the source instead of candy coating them?

The same with the rest?




More information about the openssh-unix-dev mailing list