Re: bug#70214: 'install' fails to copy regular file to autofs/cifs, due to ACL or xattr handling

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hi Pádraig,

I wrote:
> > 5) The same thing with 'cp -a' succeeds:
> > 
> > $ build-sparc64/src/cp -a /var/tmp/foo3941 $HOME/foo3941; echo $?
> > 0
> > $ build-sparc64-no-acl/src/cp -a /var/tmp/foo3941 $HOME/foo3941; echo $?
> > 0

You wrote:
> The psuedo code that install(1) uses is:
> 
> copy_reg()
>    if (x->set_mode) /* install */
>      set_acl(dest, x->mode /* 600 */)
>        ctx->acl = acl_from_mode ( /* 600 */)
>        acl_set_fd (ctx->acl) /* fails EACCES */
>        if (! acls_set)
>           must_chmod = true;
>        if (must_chmod)
>          saved_errno = EACCES;
>          chmod (ctx->mode /* 600 */)
>          if (save_errno)
>            return -1;

And, for comparison, what is the pseudo-code that 'cp -a' uses?
I would guess that there must be a relevant difference between both.

Bruno








[Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]

  Powered by Linux