[PATCH] Add SF_ARCHIVED to EPERM in chflags(2) ERROR section

Jaakko Heinonen jh at FreeBSD.org
Fri Oct 29 15:18:54 UTC 2010


On 2010-10-23, Garrett Cooper wrote:
>     The SF_ARCHIVED flag isn't noted in the chflags(2) ERROR section.
> The attached patch adds the entry.
> If no one has any objections, could someone help me commit this?

> Index: lib/libc/sys/chflags.2
> ===================================================================
> --- lib/libc/sys/chflags.2	(revision 213377)
> +++ lib/libc/sys/chflags.2	(working copy)
> @@ -148,14 +148,14 @@
>  the effective user ID is not the super-user.
>  .It Bq Er EPERM
>  One of
> -.Dv SF_IMMUTABLE , SF_APPEND ,
> +.Dv SF_ARCHIVED , SF_IMMUTABLE , SF_APPEND ,
>  or
>  .Dv SF_NOUNLINK
>  is set and the user is either not the super-user or
>  securelevel is greater than 0.

This is not correct. SF_ARCHIVED doesn't prevent setting of the flags.

>  .It Bq Er EPERM
>  A non-super-user tries to set one of
> -.Dv SF_IMMUTABLE , SF_APPEND ,
> +.Dv SF_ARCHIVED , SF_IMMUTABLE , SF_APPEND ,
>  or
>  .Dv SF_NOUNLINK .
>  .It Bq Er EPERM

I have committed this in r214514.

Thanks!

-- 
Jaakko


More information about the freebsd-hackers mailing list