MCPcopy Create free account
hub / github.com/F-Stack/f-stack / ng_address_path

Function ng_address_path

lib/ff_ng_base.c:3642–3665  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

3640}
3641
3642int
3643ng_address_path(node_p here, item_p item, const char *address, ng_ID_t retaddr)
3644{
3645 node_p dest = NULL;
3646 hook_p hook = NULL;
3647 int error;
3648
3649 ITEM_DEBUG_CHECKS;
3650 /*
3651 * Note that ng_path2noderef increments the reference count
3652 * on the node for us if it finds one. So we don't have to.
3653 */
3654 error = ng_path2noderef(here, address, &dest, &hook);
3655 if (error) {
3656 NG_FREE_ITEM(item);
3657 return (error);
3658 }
3659 NGI_SET_NODE(item, dest);
3660 if (hook)
3661 NGI_SET_HOOK(item, hook);
3662
3663 SET_RETADDR(item, here, retaddr);
3664 return (0);
3665}
3666
3667int
3668ng_address_ID(node_p here, item_p item, ng_ID_t ID, ng_ID_t retaddr)

Callers

nothing calls this directly

Calls 1

ng_path2noderefFunction · 0.70

Tested by

no test coverage detected