diff options
author | Robert Mustacchi <rm@joyent.com> | 2016-02-26 22:43:10 +0000 |
---|---|---|
committer | Robert Mustacchi <rm@joyent.com> | 2016-03-25 16:48:11 -0700 |
commit | efbf89fbc68a0864d303fe237fc420cf018d52f7 (patch) | |
tree | c15577195b383276346b1b2c9ad35327e9e1e065 | |
parent | a6ae009119d792a981d8b7153f8cb3851fe04ebb (diff) | |
download | illumos-joyent-efbf89fbc68a0864d303fe237fc420cf018d52f7.tar.gz |
6497 nvlist_empty() needs to appear in man pages
Reviewed by: Yuri Pankov <yuri.pankov@nexenta.com>
Reviewed by: Volker A. Brandt <vab@bb-c.de>
Reviewed by: Marcel Telka <marcel@telka.sk>
Reviewed by: Albert Lee <trisk@omniti.com>
Approved by: Hans Rosenfeld <rosenfeld@grumpf.hope-2000.org>
-rw-r--r-- | usr/src/man/man3lib/libnvpair.3lib | 10 | ||||
-rw-r--r-- | usr/src/man/man3nvpair/Makefile | 2 | ||||
-rw-r--r-- | usr/src/man/man3nvpair/nvlist_lookup_nvpair.3nvpair | 23 | ||||
-rw-r--r-- | usr/src/pkg/manifests/system-library.man3nvpair.inc | 2 |
4 files changed, 23 insertions, 14 deletions
diff --git a/usr/src/man/man3lib/libnvpair.3lib b/usr/src/man/man3lib/libnvpair.3lib index 947fbf6b48..0279ba94a2 100644 --- a/usr/src/man/man3lib/libnvpair.3lib +++ b/usr/src/man/man3lib/libnvpair.3lib @@ -3,7 +3,7 @@ .\" The contents of this file are subject to the terms of the Common Development and Distribution License (the "License"). You may not use this file except in compliance with the License. .\" You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE or http://www.opensolaris.org/os/licensing. See the License for the specific language governing permissions and limitations under the License. .\" When distributing Covered Code, include this CDDL HEADER in each file and include the License file at usr/src/OPENSOLARIS.LICENSE. If applicable, add the following below this CDDL HEADER, with the fields enclosed by brackets "[]" replaced with your own identifying information: Portions Copyright [yyyy] [name of copyright owner] -.TH LIBNVPAIR 3LIB "Aug 1, 2008" +.TH LIBNVPAIR 3LIB "Mar 13, 2016" .SH NAME libnvpair \- name-value pair library .SH SYNOPSIS @@ -14,7 +14,6 @@ cc [ \fIflag\fR... ] \fIfile\fR... \fB-lnvpair\fR [ \fIlibrary\fR... ] .fi .SH DESCRIPTION -.sp .LP The \fBlibnvpair\fR library exports a set of functions for managing name-value pairs. @@ -97,7 +96,6 @@ Pack an \fBnvlist_t\fR into a contiguous buffer. Expand a packed nvlist into a searchable \fBnvlist_t\fR. .RE .SH INTERFACES -.sp .LP The shared object \fBlibnvpair.so.1\fR provides the public interfaces defined below. See \fBIntro\fR(3) for additional information on shared object @@ -122,7 +120,8 @@ l l . \fBnvlist_add_uint16_array\fR \fBnvlist_add_uint32\fR \fBnvlist_add_uint32_array\fR \fBnvlist_add_uint64\fR \fBnvlist_add_uint64_array\fR \fBnvlist_alloc\fR -\fBnvlist_dup\fR \fBnvlist_exists\fR +\fBnvlist_dup\fR \fBnvpair_empty\fR +\fBnvlist_exists\fR \fBnvlist_free\fR \fBnvlist_lookup_boolean\fR \fBnvlist_lookup_boolean_value\fR \fBnvlist_lookup_boolean_array\fR \fBnvlist_lookup_byte\fR \fBnvlist_lookup_byte_array\fR @@ -162,7 +161,6 @@ l l . .TE .SH FILES -.sp .ne 2 .na \fB\fB/lib/libnvpair.so.1\fR\fR @@ -181,7 +179,6 @@ shared object .RE .SH ATTRIBUTES -.sp .LP See \fBattributes\fR(5) for description of the following attributes: .sp @@ -199,6 +196,5 @@ MT-Level MT-Safe .TE .SH SEE ALSO -.sp .LP \fBIntro\fR(3), \fBattributes\fR(5) diff --git a/usr/src/man/man3nvpair/Makefile b/usr/src/man/man3nvpair/Makefile index 3cdd21e34d..9366fcc54b 100644 --- a/usr/src/man/man3nvpair/Makefile +++ b/usr/src/man/man3nvpair/Makefile @@ -56,6 +56,7 @@ MANLINKS= nv_alloc_fini.3nvpair \ nvlist_add_uint8.3nvpair \ nvlist_add_uint8_array.3nvpair \ nvlist_dup.3nvpair \ + nvlist_empty.3nvpair \ nvlist_exists.3nvpair \ nvlist_free.3nvpair \ nvlist_lookup_boolean_array.3nvpair \ @@ -190,6 +191,7 @@ nvlist_lookup_uint64_array.3nvpair := LINKSRC = nvlist_lookup_boolean.3nvpair nvlist_lookup_uint8.3nvpair := LINKSRC = nvlist_lookup_boolean.3nvpair nvlist_lookup_uint8_array.3nvpair := LINKSRC = nvlist_lookup_boolean.3nvpair +nvlist_empty.3nvpair := LINKSRC = nvlist_lookup_nvpair.3nvpair nvlist_exists.3nvpair := LINKSRC = nvlist_lookup_nvpair.3nvpair nvpair_name.3nvpair := LINKSRC = nvlist_next_nvpair.3nvpair diff --git a/usr/src/man/man3nvpair/nvlist_lookup_nvpair.3nvpair b/usr/src/man/man3nvpair/nvlist_lookup_nvpair.3nvpair index f83435a51c..05799bf2a2 100644 --- a/usr/src/man/man3nvpair/nvlist_lookup_nvpair.3nvpair +++ b/usr/src/man/man3nvpair/nvlist_lookup_nvpair.3nvpair @@ -1,11 +1,12 @@ '\" te .\" Copyright (c) 2007, Sun Microsystems Inc. All Rights Reserved. +.\" Copyright 2016 Joyent, Inc. .\" The contents of this file are subject to the terms of the Common Development and Distribution License (the "License"). You may not use this file except in compliance with the License. .\" You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE or http://www.opensolaris.org/os/licensing. See the License for the specific language governing permissions and limitations under the License. .\" When distributing Covered Code, include this CDDL HEADER in each file and include the License file at usr/src/OPENSOLARIS.LICENSE. If applicable, add the following below this CDDL HEADER, with the fields enclosed by brackets "[]" replaced with your own identifying information: Portions Copyright [yyyy] [name of copyright owner] -.TH NVLIST_LOOKUP_NVPAIR 3NVPAIR "Oct 24, 2007" +.TH NVLIST_LOOKUP_NVPAIR 3NVPAIR "Mar 13, 2016" .SH NAME -nvlist_lookup_nvpair, nvlist_exists \- lookup named pairs +nvlist_lookup_nvpair, nvlist_exists, nvlist_empty \- lookup named pairs .SH SYNOPSIS .LP .nf @@ -21,8 +22,12 @@ nvlist_lookup_nvpair, nvlist_exists \- lookup named pairs \fBboolean_t\fR \fBnvlist_exists\fR(\fBnvlist_t *\fR\fInvl\fR, \fBconst char *\fR\fIname\fR); .fi +.LP +.nf +\fBboolean_t\fR \fBnvlist_empty\fR(\fBnvlist_t *\fR\fInvl\fR); +.fi + .SH DESCRIPTION -.sp .LP The \fBnvlist_lookup_nvpair()\fR function returns the nvpair with the matching name, regardless of type. It is valid only for lists allocated with @@ -31,18 +36,24 @@ name, regardless of type. It is valid only for lists allocated with .LP The \fBnvlist_exists()\fR function returns success if any nvpair exists with the given name. It is valid for all types of lists. -.SH RETURN VALUES .sp .LP +The \fBnvlist_empty()\fR function returns success if the list \fInvl\fR +contains no nvpairs. It is valid for all types of lists. +.SH RETURN VALUES +.LP The \fBnvlist_lookup_nvpair()\fR function returns 0 on success and an error value on failure. .sp .LP The \fBnvlist_exists()\fR function returns \fBB_TRUE\fR if an nvpair with the given name exists and \fBB_FALSE\fR otherwise. -.SH ERRORS .sp .LP +The \fBnvlist_empty()\fR function returns \fBB_TRUE\fR if the given +list, \fInvl\fR, contains no nvpairs and \fBB_FALSE\fR otherwise. +.SH ERRORS +.LP The \fBnvlist_lookup_nvpair()\fR function will fail if: .sp .ne 2 @@ -72,7 +83,6 @@ The list was not allocated with \fBNV_UNIQUE_NAME\fR. .RE .SH ATTRIBUTES -.sp .LP See \fBattributes\fR(5) for descriptions of the following attributes: .sp @@ -90,7 +100,6 @@ MT-Level MT-Safe .TE .SH SEE ALSO -.sp .LP \fBlibnvpair\fR(3LIB), \fBnvlist_alloc\fR(3NVPAIR), \fBattributes\fR(5), \fBnvlist_lookup_nvpair\fR(9F) diff --git a/usr/src/pkg/manifests/system-library.man3nvpair.inc b/usr/src/pkg/manifests/system-library.man3nvpair.inc index 1227925932..397b1bd38e 100644 --- a/usr/src/pkg/manifests/system-library.man3nvpair.inc +++ b/usr/src/pkg/manifests/system-library.man3nvpair.inc @@ -81,6 +81,8 @@ link path=usr/share/man/man3nvpair/nvlist_add_uint8_array.3nvpair \ target=nvlist_add_boolean.3nvpair link path=usr/share/man/man3nvpair/nvlist_dup.3nvpair \ target=nvlist_alloc.3nvpair +link path=usr/share/man/man3nvpair/nvlist_empty.3nvpair \ + target=nvlist_lookup_nvpair.3nvpair link path=usr/share/man/man3nvpair/nvlist_exists.3nvpair \ target=nvlist_lookup_nvpair.3nvpair link path=usr/share/man/man3nvpair/nvlist_free.3nvpair \ |