Skip to content

Commit 3948c19

Browse files
author
hackorum
committed
Apply objaddr-warn.patch
1 parent 31878cc commit 3948c19

1 file changed

Lines changed: 5 additions & 2 deletions

File tree

‎src/backend/catalog/objectaddress.c‎

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1698,8 +1698,8 @@ get_object_address_opf_member(ObjectType objtype,
16981698
ObjectAddress address;
16991699
ListCell *cell;
17001700
List *copy;
1701-
TypeName *typenames[2];
1702-
Oid typeoids[2];
1701+
TypeName *typenames[2] = { NULL, NULL };
1702+
Oid typeoids[2] = { InvalidOid, InvalidOid };
17031703
int membernum;
17041704
int i;
17051705

@@ -1729,6 +1729,9 @@ get_object_address_opf_member(ObjectType objtype,
17291729
break;
17301730
}
17311731

1732+
Assert(typenames[0] != NULL && typenames[1] != NULL);
1733+
Assert(typeoids[0] != InvalidOid && typeoids[1] != InvalidOid);
1734+
17321735
switch (objtype)
17331736
{
17341737
case OBJECT_AMOP:

0 commit comments

Comments
 (0)