More issues with expressions always false (no patch)
Ranier Vilela <ranier.vf@gmail.com>
From: Ranier Vilela <ranier.vf@gmail.com>
To: pgsql-hackers@lists.postgresql.org
Date: 2019-12-20T00:01:11Z
Lists: pgsql-hackers
Continuing on always false expressions. There are three difficult cases, whose solutions which needs to be well thought out. This is not a case of simply removing the expressions, perhaps, but have to be sure. First case: src \ backend \ executor \ nodeSubplan.c (line 507) if (node-> hashtable) node-> hastable is assigned with NULL at line 498, so the test will always fail. Second case: Here the case is similar, but worse. src \ backend \ executor \ nodeSubplan.c (line 535) if (node-> hashnulls) ResetTupleHashTable (node-> hashtable); node-> hashnulls is assigned with NULL at line 499, so the test will always fail. Otherwise, it would have already been discovered, because it would inevitably occur an access violation, since > hashtable would be accessed. Third case: \ src \ backend \ utils \ cache \ relcache.c (line 5190) if (relation-> rd_pubactions) It will never be executed, because if relation-> rd_pubactions is true, the function returns on line 5154. regards, Ranier Vilela
Commits
-
Correctly re-use hash tables in buildSubPlanHash().
- 9eb6b652a46d 11.8 landed
- 96d783ae55b9 12.3 landed
- 58c47ccfff20 13.0 landed
-
Reset, not recreate, execGrouping.c style hashtables.
- 356687bd825e 12.0 cited