Martijn van Oosterhout <kleptog@svana.org> writes:
> Attached is a patch that fixes two non-bugs. There's plenty of
> redundant NULL checks around the place but these were just so silly I
> figure they're worth fixing.

> The first checks 'file' the line after having dereferenced it. The
> second checks 'currSchema' where the code is designed to never allow it
> to be NULL.

The first patch looks reasonable but I object to the second.  Coverity
is not going to dictate coding conventions to us --- it is not *nearly*
bright enough for that.  In this case, the code is locally allowing for
the possibility that AH->currSchema was NULL, and I don't consider it
good style to remove that allowance.  (I take it BTW that this allegedly
bulletproof tool fails to consider the possibility that strdup fails
and returns NULL ...)

                        regards, tom lane

---------------------------(end of broadcast)---------------------------
TIP 3: Have you checked our extensive FAQ?

               http://www.postgresql.org/docs/faq

Reply via email to