Re: Suspicious strcmp() in src/backend/parser/parse_expr.c

Michael Paquier <michael@paquier.xyz>

From: Michael Paquier <michael@paquier.xyz>
To: Tom Lane <tgl@sss.pgh.pa.us>
Cc: Andrew Gierth <andrew@tao11.riddles.org.uk>, Rikard Falkeborn <rikard.falkeborn@gmail.com>, pgsql-bugs@lists.postgresql.org
Date: 2019-04-11T06:50:55Z
Lists: pgsql-bugs

Attachments

On Thu, Apr 11, 2019 at 12:55:49AM -0400, Tom Lane wrote:
> I'd be +1 for that, just on the grounds of having consistent coding
> style.  But I'm not sufficiently excited about it to do the work
> myself ...

Well, here you go as per the attached as we are on it.  I am not
noticing any other spots.
--
Michael

Commits

  1. Fix more strcmp() calls using boolean-like comparisons for result checks

  2. Fix backwards test in operator_precedence_warning logic.