This is the mail archive of the
cygwin-developers
mailing list for the Cygwin project.
Re: Bug or feature missing in rsync.
- From: Dave Korn <dave dot korn dot cygwin at googlemail dot com>
- To: Dave Korn <dave dot korn dot cygwin at googlemail dot com>
- Cc: cygwin-developers at cygwin dot com
- Date: Wed, 16 Sep 2009 15:50:33 +0100
- Subject: Re: Bug or feature missing in rsync.
- References: <4AA61819.4030501@tlinx.org> <4AB0A9CD.3090201@lapo.it> <4AB0AEBC.6090709@lapo.it> <4AB0D66D.4000204@gmail.com> <4AB0E914.2060704@lapo.it> <4AB0EF6C.70605@lapo.it> <4AB0F823.6010100@gmail.com> <4AB0F901.2090707@gmail.com>
Dave Korn wrote:
>
> Ah, looks like Cygwin only supports xattr on Samba filesystems.
Or that could just be a logic bug.
> int __stdcall
> write_ea (HANDLE hdl, path_conv &pc, const char *name, const char *value,
> size_t size, int flags)
> {
> OBJECT_ATTRIBUTES attr;
> NTSTATUS status;
> IO_STATUS_BLOCK io;
> int ret = -1;
> HANDLE h = hdl;
> PFILE_FULL_EA_INFORMATION fea;
> ULONG flen;
> size_t nlen;
>
> myfault efault;
> if (efault.faulted (EFAULT))
> goto out;
>
> pc.get_object_attr (attr, sec_none_nih);
>
> debug_printf ("write_ea (%S, %s, %p, %lu, %d)",
> attr.ObjectName, name, value, size, flags);
>
> /* Samba hides the user namespace from Windows clients. If we get a
> user namespace item, we remove the leading namespace from the name.
> This keeps tools like attr/getfattr/setfattr happy. Otherwise
> setting the EA fails as if we don't have the permissions. */
> if (pc.fs_is_samba () && ascii_strncasematch (name, "user.", 5))
> name += 5;
> else
> {
> set_errno (EOPNOTSUPP);
> goto out;
> }
I wonder if that unconditional else clause should in fact be "else if
(pc.fs_is_samba())"?
cheers,
DaveK