"GOT", but the "O" is a cute, smiling sun Index | Thread

From:
Stefan Sperling <stsp@stsp.name>
Subject:
Re: unsigned char cast for is* ctype.h macros
To:
Omar Polo <op@omarpolo.com>
Cc:
gameoftrees@openbsd.org
Date:
Thu, 17 Nov 2022 10:48:44 +0100

Download raw body.

On Thu, Nov 17, 2022 at 10:26:41AM +0100, Omar Polo wrote:
> forgot to catch an isalpha in diff_output.c

> --- lib/diff_output.c
> +++ lib/diff_output.c
> @@ -262,7 +262,7 @@ is_function_prototype(unsigned char ch)
>  static bool
>  is_function_prototype(unsigned char ch)
>  {
> -	return (isalpha(ch) || ch == '_' || ch == '$');
> +	return (isalpha((unsigned char) ch) || ch == '_' || ch == '$');

Maybe drop the space between ) and ch?

In any case, still OK by me.