We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 9e92853 commit 7d89e46Copy full SHA for 7d89e46
src/auth.c
@@ -99,10 +99,11 @@ static bool is_metadata_relation(Oid relation_oid)
99
if (namespace_oid == PG_CATALOG_NAMESPACE)
100
return true; /* PG_CATALOG relations are checked in `ExecutorCheckPerms` hook. */
101
102
- if (strcmp(get_namespace_name(namespace_oid), "information_schema") == 0)
103
- return true; /* INFORMATION_SCHEMA relations are safe to query. */
+ char *namespace_name = get_namespace_name(namespace_oid);
+ bool result = strcmp(namespace_name, "information_schema") == 0; /* INFORMATION_SCHEMA relations are safe to query. */
104
+ pfree(namespace_name);
105
- return false;
106
+ return result;
107
}
108
109
bool is_personal_relation(Oid relation_oid)
0 commit comments