提交 770ad742 编写于 作者: D Daniel Gustafsson

Fix two NULL related warnings in resource queue/groups

Passing InvalidOid to as a HeapTuple argument cause a warning for
NULL pointer constant, replace InvalidOid with NULL in call to
AlterResqueueCapabilityEntry() to avoid. Also initialize the owner
in GetResGroupIdForRole() since we otherwise read an uninitialized
value in case the CurrentResourceOwner was set.
上级 d8ac3308
......@@ -585,7 +585,7 @@ AlterResqueueCapabilityEntry(Oid queueid,
resTypeInt,
pResSetting,
rel,
InvalidOid);
NULL /* InvalidOid */);
}
} /* end foreach elem */
......
......@@ -329,7 +329,7 @@ Oid
GetResGroupIdForRole(Oid roleid)
{
HeapTuple tuple;
ResourceOwner owner;
ResourceOwner owner = NULL;
Oid groupId;
Relation rel;
ScanKeyData key;
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册