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

Function nvlist_move_binary

freebsd/contrib/libnv/nvlist.c:1738–1756  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

1736#endif
1737
1738void
1739nvlist_move_binary(nvlist_t *nvl, const char *name, void *value, size_t size)
1740{
1741 nvpair_t *nvp;
1742
1743 if (nvlist_error(nvl) != 0) {
1744 nv_free(value);
1745 ERRNO_SET(nvlist_error(nvl));
1746 return;
1747 }
1748
1749 nvp = nvpair_move_binary(name, value, size);
1750 if (nvp == NULL) {
1751 nvl->nvl_error = ERRNO_OR_DEFAULT(ENOMEM);
1752 ERRNO_SET(nvl->nvl_error);
1753 } else {
1754 (void)nvlist_move_nvpair(nvl, nvp);
1755 }
1756}
1757
1758void
1759nvlist_move_bool_array(nvlist_t *nvl, const char *name, bool *value,

Callers

nothing calls this directly

Calls 2

nvlist_errorFunction · 0.85
nvpair_move_binaryFunction · 0.85

Tested by

no test coverage detected