| 1715 | |
| 1716 | #ifndef _KERNEL |
| 1717 | void |
| 1718 | nvlist_move_descriptor(nvlist_t *nvl, const char *name, int value) |
| 1719 | { |
| 1720 | nvpair_t *nvp; |
| 1721 | |
| 1722 | if (nvlist_error(nvl) != 0) { |
| 1723 | close(value); |
| 1724 | ERRNO_SET(nvlist_error(nvl)); |
| 1725 | return; |
| 1726 | } |
| 1727 | |
| 1728 | nvp = nvpair_move_descriptor(name, value); |
| 1729 | if (nvp == NULL) { |
| 1730 | nvl->nvl_error = ERRNO_OR_DEFAULT(ENOMEM); |
| 1731 | ERRNO_SET(nvl->nvl_error); |
| 1732 | } else { |
| 1733 | (void)nvlist_move_nvpair(nvl, nvp); |
| 1734 | } |
| 1735 | } |
| 1736 | #endif |
| 1737 | |
| 1738 | void |
nothing calls this directly
no test coverage detected