Guard against missing address function

velioglu/cyclic_dep_with_tho
Burak Velioglu 2022-03-07 15:29:02 +03:00
parent 9b583fdb0d
commit 29ed28623d
No known key found for this signature in database
GPG Key ID: F6827E620F6549C6
1 changed files with 5 additions and 2 deletions

View File

@ -666,8 +666,11 @@ ProcessUtilityInternal(PlannedStmt *pstmt,
* MarkObjectDistributedLocally since altering already distributed object won't
* call MarkObjectDistributedLocally but will hit the check here.
*/
ObjectAddress targetObject = GetObjectAddressFromParseTree(parsetree, false);
ErrorIfCircularDependencyExists(&targetObject);
if (ops && ops->address)
{
ObjectAddress targetObject = GetObjectAddressFromParseTree(parsetree, true);
ErrorIfCircularDependencyExists(&targetObject);
}
if (ops && ops->postprocess)
{