pgsql: Fix compilation warning of pg_basebackup with MinGW

2019-07-21 Thread Michael Paquier
Fix compilation warning of pg_basebackup with MinGW Several buildfarm members have been complaining about that with gcc, like jacana. Weirdly enough, Visual Studio's compilers do not find this issue. Author: Michael Paquier Reviewed-by: Andrew Dunstan Discussion: https://postgr.es/m/201907190508

pgsql: Remove no-longer-helpful reliance on fixed-size local array.

2019-07-21 Thread Tom Lane
Remove no-longer-helpful reliance on fixed-size local array. Coverity complained about this code, apparently because it uses a local array of size FUNC_MAX_ARGS without a guard that the input argument list is no longer than that. (Not sure why it complained today, since this code's been the same

pgsql: Adjust overly strict Assert

2019-07-21 Thread David Rowley
Adjust overly strict Assert 3373c7155 changed how we determine EquivalenceClasses for relations and added an Assert to ensure all relations mentioned in each EC's ec_relids was a RELOPT_BASEREL. However, the join removal code may remove a LEFT JOIN and since it does not clean up EC members belong

pgsql: Fix inconsistencies and typos in the tree

2019-07-21 Thread Michael Paquier
Fix inconsistencies and typos in the tree This is numbered take 7, and addresses a set of issues with code comments, variable names and unreferenced variables. Author: Alexander Lakhin Discussion: https://postgr.es/m/[email protected] Branch -- master Details --