SQLBOX_ROLE_HIER_CHILD(3) Library Functions Manual SQLBOX_ROLE_HIER_CHILD(3)

sqlbox_role_hier_child
add a child to a role

library “sqlbox”

#include <stdint.h>
#include <sqlbox.h>

int
sqlbox_role_hier_child(struct sqlbox_role_hier *p, size_t parent, size_t child);

Set parent to be the parent of role child in the hierarchy generator p. In the hierarchical structure created by sqlbox_role_hier_child(), a node may have at most one parent.

Returns zero if child or parent is an invalid role, if child already has a parent set, if either child or parent are a sink or start role, or if child is already an ancestor to parent. Returns non-zero otherwise.

sqlbox_role_hier_alloc(3)
November 1, 2019 OpenBSD 6.5