Subject: Re: bug#70182: [PATCH] Fix + ert for segmentation fault in get-variable-watchers (1 of 9)

From: Eli Zaretskii <[email-masked]>
Date: Sat, 06 Apr 2024 10:25:11 +0300

> From: Robert Burks <[email-masked]>
> Date: Thu, 4 Apr 2024 04:44:22 -0400
> 
> +++ b/src/data.c
> @@ -1838,7 +1838,7 @@ SYMBOL (or its aliases) are set.  */)
>    (Lisp_Object symbol, Lisp_Object watch_function)
>  {
>    symbol = Findirect_variable (symbol);
> -  Lisp_Object watchers = Fget (symbol, Qwatchers);
> +  Lisp_Object watchers = Fget (symbol, Qwatchers); /* CHECK_SYMBOL is in Fget */

This commentary is not needed here, so please remove it.

Also, please note that our conventions are to end a comment in a
period and two spaces.

> +  symbol = Findirect_variable (symbol);
> +  CHECK_SYMBOL (symbol); /* BUG#00000 Must guard SYMBOL_TRAPPED_WRITE_P */

This comment is also redundant: the fact that we check a symbol
doesn't need any explanations.

Thanks.