All of lore.kernel.org
 help / color / mirror / Atom feed
From: Goldwyn Rodrigues <rgoldwyn-l3A5Bk7waGM@public.gmane.org>
To: linux-man-u79uwXL29TY76Z2rM5mHXA@public.gmane.org
Cc: jstancek-H+wXaHxf7aLQT0dZR+AlfA@public.gmane.org,
	mszeredi-H+wXaHxf7aLQT0dZR+AlfA@public.gmane.org,
	linux-api-u79uwXL29TY76Z2rM5mHXA@public.gmane.org,
	mtk.manpages-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org,
	chrubis-AlSwsSmVLrQ@public.gmane.org,
	tytso-3s7WtUTddSA@public.gmane.org,
	bfields-uC3wQj2KruNg9hUCZPvPmw@public.gmane.org,
	pgajdos-IBi9RG/b67k@public.gmane.org,
	Goldwyn Rodrigues <rgoldwyn-IBi9RG/b67k@public.gmane.org>
Subject: [PATCH] utimensat: immutable flag returns -EPERM
Date: Mon,  5 Jun 2017 09:18:27 -0500	[thread overview]
Message-ID: <20170605141827.21420-1-rgoldwyn@suse.de> (raw)

From: Goldwyn Rodrigues <rgoldwyn-IBi9RG/b67k@public.gmane.org>

Linux kernel commit 337684a1746f "fs: return EPERM on immutable inode"
changed (nd unified the return value of the utimensat(2) from -EACCES
to -EPERM in case of an immutable flag. Modify the man page to
reflect the same.

The entire discussion of returning the correct return value is at:
http://lists.linux.it/pipermail/ltp/2017-January/003424.html

Signed-off-by: Goldwyn Rodrigues <rgoldwyn-IBi9RG/b67k@public.gmane.org>
---
 man2/utimensat.2 | 10 ++--------
 1 file changed, 2 insertions(+), 8 deletions(-)

diff --git a/man2/utimensat.2 b/man2/utimensat.2
index f77d0b42a..c0bdf8808 100644
--- a/man2/utimensat.2
+++ b/man2/utimensat.2
@@ -238,10 +238,7 @@ or both
 .I tv_nsec
 values are
 .BR UTIME_NOW ,
-and either:
-.RS
-.IP * 3
-the effective user ID of the caller does not match
+and the effective user ID of the caller does not match
 the owner of the file,
 the caller does not have write access to the file,
 and the caller is not privileged
@@ -249,7 +246,7 @@ and the caller is not privileged
 .B CAP_FOWNER
 or the
 .B CAP_DAC_OVERRIDE
-capability); or,
+capability).
 .\" But Linux 2.6.22 was broken here.
 .\" Traditionally, utime()/utimes() gives the error EACCES for the case
 .\" where the timestamp pointer argument is NULL (i.e., set both timestamps
@@ -271,9 +268,6 @@ capability); or,
 .\" and the permissions of the directory to which
 .\" .I fd
 .\" refers do not allow searches.
-.IP *
-the file is marked immutable (see
-.BR chattr (1)).
 .\" EXT2_IMMUTABLE_FL and similar flags for other filesystems.
 .RE
 .TP
-- 
2.12.3

             reply	other threads:[~2017-06-05 14:18 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-06-05 14:18 Goldwyn Rodrigues [this message]
2020-04-14  9:25 ` [PATCH] utimensat: immutable flag returns -EPERM Michael Kerrisk (man-pages)

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=20170605141827.21420-1-rgoldwyn@suse.de \
    --to=rgoldwyn-l3a5bk7wagm@public.gmane.org \
    --cc=bfields-uC3wQj2KruNg9hUCZPvPmw@public.gmane.org \
    --cc=chrubis-AlSwsSmVLrQ@public.gmane.org \
    --cc=jstancek-H+wXaHxf7aLQT0dZR+AlfA@public.gmane.org \
    --cc=linux-api-u79uwXL29TY76Z2rM5mHXA@public.gmane.org \
    --cc=linux-man-u79uwXL29TY76Z2rM5mHXA@public.gmane.org \
    --cc=mszeredi-H+wXaHxf7aLQT0dZR+AlfA@public.gmane.org \
    --cc=mtk.manpages-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org \
    --cc=pgajdos-IBi9RG/b67k@public.gmane.org \
    --cc=rgoldwyn-IBi9RG/b67k@public.gmane.org \
    --cc=tytso-3s7WtUTddSA@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.