All of lore.kernel.org
 help / color / mirror / Atom feed
From: "Michael Kerrisk (man-pages)" <mtk.manpages-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org>
To: Abhay Sachan <sachan.abhay-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org>
Cc: mtk.manpages-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org,
	linux-man-u79uwXL29TY76Z2rM5mHXA@public.gmane.org
Subject: Re: [patch] getxattr.2 : Fix RETURN VALUE description
Date: Sun, 06 Apr 2014 10:40:59 +0200	[thread overview]
Message-ID: <5341131B.4040405@gmail.com> (raw)
In-Reply-To: <CAFfPn7jvbk=V8b1yYq5mvB9dy_aZrL=-ngYz8FDnDiAgK4KO5A-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org>

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

      parent reply	other threads:[~2014-04-06  8:40 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [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 message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=5341131B.4040405@gmail.com \
    --to=mtk.manpages-re5jqeeqqe8avxtiumwx3w@public.gmane.org \
    --cc=linux-man-u79uwXL29TY76Z2rM5mHXA@public.gmane.org \
    --cc=sachan.abhay-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
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.