* Fwd: [patch] getxattr.2 : Fix RETURN VALUE description
[not found] ` <CAFfPn7jvbk=V8b1yYq5mvB9dy_aZrL=-ngYz8FDnDiAgK4KO5A-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org>
@ 2014-04-06 8:35 ` Abhay Sachan
2014-04-06 8:40 ` Michael Kerrisk (man-pages)
1 sibling, 0 replies; 2+ messages in thread
From: Abhay Sachan @ 2014-04-06 8:35 UTC (permalink / raw)
To: mtk.manpages-Re5JQEeQqe8AvxtiuMwx3w; +Cc: linux-man-u79uwXL29TY76Z2rM5mHXA
Hi,
The manpage for getxattr() says : "On success, a positive number
is returned indicating the size of the extended attribute value."
But in case the value length is zero, we should return the size as
zero (as is done by ext4, xfs). Thus "positive" number kind looks
misleading. So it should be changed to "nonnegative".
--Abhay
diff --git a/man2/getxattr.2 b/man2/getxattr.2
index adc7617..c343c34 100644
--- a/man2/getxattr.2
+++ b/man2/getxattr.2
@@ -98,7 +98,7 @@ The interface is designed to allow guessing of initial buffer
sizes, and to enlarge buffers when the return value indicates
that the buffer provided was too small.
.SH RETURN VALUE
-On success, a positive number is returned indicating the size of the
+On success, a nonnegative number is returned indicating the size of the
extended attribute value.
On failure, \-1 is returned and
.I errno
--
To unsubscribe from this list: send the line "unsubscribe linux-man" in
the body of a message to majordomo-u79uwXL29TY76Z2rM5mHXA@public.gmane.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
^ permalink raw reply related [flat|nested] 2+ messages in thread
* Re: [patch] getxattr.2 : Fix RETURN VALUE description
[not found] ` <CAFfPn7jvbk=V8b1yYq5mvB9dy_aZrL=-ngYz8FDnDiAgK4KO5A-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org>
2014-04-06 8:35 ` Fwd: [patch] getxattr.2 : Fix RETURN VALUE description Abhay Sachan
@ 2014-04-06 8:40 ` Michael Kerrisk (man-pages)
1 sibling, 0 replies; 2+ messages in thread
From: Michael Kerrisk (man-pages) @ 2014-04-06 8:40 UTC (permalink / raw)
To: Abhay Sachan
Cc: mtk.manpages-Re5JQEeQqe8AvxtiuMwx3w, linux-man-u79uwXL29TY76Z2rM5mHXA
On 04/05/2014 11:25 PM, Abhay Sachan wrote:
> Hi,
>
> The manpage for getxattr() says : "On success, a positive number
> is returned indicating the size of the extended attribute value."
>
> But in case the value length is zero, we should return the size as
> zero (as is done by ext4, xfs). Thus "positive" number kind looks
> misleading. So it should be changed to "nonnegative".
Thanks, Abhay. Applied.
Cheers,
Michael
> diff --git a/man2/getxattr.2 b/man2/getxattr.2
> index adc7617..c343c34 100644
> --- a/man2/getxattr.2
> +++ b/man2/getxattr.2
> @@ -98,7 +98,7 @@ The interface is designed to allow guessing of initial buffer
> sizes, and to enlarge buffers when the return value indicates
> that the buffer provided was too small.
> .SH RETURN VALUE
> -On success, a positive number is returned indicating the size of the
> +On success, a nonnegative number is returned indicating the size of the
> extended attribute value.
> On failure, \-1 is returned and
> .I errno
>
>
--
Michael Kerrisk
Linux man-pages maintainer; http://www.kernel.org/doc/man-pages/
Linux/UNIX System Programming Training: http://man7.org/training/
--
To unsubscribe from this list: send the line "unsubscribe linux-man" in
the body of a message to majordomo-u79uwXL29TY76Z2rM5mHXA@public.gmane.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2014-04-06 8:40 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
[not found] <CAFfPn7jvbk=V8b1yYq5mvB9dy_aZrL=-ngYz8FDnDiAgK4KO5A@mail.gmail.com>
[not found] ` <CAFfPn7jvbk=V8b1yYq5mvB9dy_aZrL=-ngYz8FDnDiAgK4KO5A-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org>
2014-04-06 8:35 ` Fwd: [patch] getxattr.2 : Fix RETURN VALUE description Abhay Sachan
2014-04-06 8:40 ` Michael Kerrisk (man-pages)
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.