Re: wrong comments in ClassifyUtilityCommandAsReadOnly

David Rowley <dgrowleyml@gmail.com>

From: David Rowley <dgrowleyml@gmail.com>
To: jian he <jian.universality@gmail.com>
Cc: PostgreSQL Hackers <pgsql-hackers@lists.postgresql.org>
Date: 2024-12-23T02:43:09Z
Lists: pgsql-hackers

Attachments

On Sat, 21 Dec 2024 at 17:06, jian he <jian.universality@gmail.com> wrote:
>  * Note the definitions of the relevant flags in src/include/utility/tcop.h.
>  */
> static int
> ClassifyUtilityCommandAsReadOnly(Node *parsetree)
>
> Is the comment wrong?
>
> it should be
> " * Note the definitions of the relevant flags in src/include/tcop/utility.h."

Yeah. There is no tcop.h.

 I used the attached (not exactly very pretty) script to find a few more.

git grep -h -E "\Wsrc/[\w_/]*" -- '*.[ch]' | tr -d '"' | tr -d \'\" |
xargs -n 1 ./fileexists.sh | grep "does not"

There are plenty of places that reference files not starting with
"src/". It might be good to verify there's some subdirectory in the
source tree that match those, however, I didn't think of a creative
way to identify those ones.

David

Commits

  1. Fix incorrect source filename references