MCPcopy Create free account
hub / github.com/documentdb/documentdb / FreeRoleInheritanceTable

Function FreeRoleInheritanceTable

pg_documentdb/src/commands/roles.c:1689–1709  ·  view source on GitHub ↗

* FreeRoleInheritanceTable releases all memory associated with the table. */

Source from the content-addressed store, hash-verified

1687 * FreeRoleInheritanceTable releases all memory associated with the table.
1688 */
1689static void
1690FreeRoleInheritanceTable(HTAB *roleInheritanceTable)
1691{
1692 if (roleInheritanceTable == NULL)
1693 {
1694 return;
1695 }
1696
1697 HASH_SEQ_STATUS status;
1698 RoleParentEntry *entry;
1699 hash_seq_init(&status, roleInheritanceTable);
1700 while ((entry = hash_seq_search(&status)) != NULL)
1701 {
1702 if (entry->parentRoles != NIL)
1703 {
1704 list_free_deep(entry->parentRoles);
1705 }
1706 }
1707
1708 hash_destroy(roleInheritanceTable);
1709}
1710
1711
1712/*

Callers 1

roles_infoFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected