mirror of
https://github.com/postgres/postgres.git
synced 2026-06-11 01:30:11 -04:00
Fix crash in test function on removable_cutoff(NULL)
The function is part of the injection_points test module and only used in tests. None of the current tests call it with a NULL argument, but it is supposed to work. Backpatch-through: 17
This commit is contained in:
parent
1c64d2fcbe
commit
71379663fe
1 changed files with 1 additions and 1 deletions
|
|
@ -50,7 +50,7 @@ removable_cutoff(PG_FUNCTION_ARGS)
|
|||
if (!PG_ARGISNULL(0))
|
||||
rel = table_open(PG_GETARG_OID(0), AccessShareLock);
|
||||
|
||||
if (!rel->rd_rel->relisshared && autovacuum_start_daemon)
|
||||
if (rel != NULL && !rel->rd_rel->relisshared && autovacuum_start_daemon)
|
||||
elog(WARNING,
|
||||
"removable_cutoff(non-shared-rel) can move backward under autovacuum=on");
|
||||
|
||||
|
|
|
|||
Loading…
Reference in a new issue