Comment 50 for bug 1048059

Revision history for this message
Jan Claeys (janc) wrote :

So I did have a look at the source of udisks2 (this is in 'udiskslinuxfilesystem.c') and the reason for why this happens as it does is obvious (the reason WHY the code does it like this is less obvious to me though...).

If '/media/$USER' does not exist, Udisks 2 checks if '/media' exists and if not creates it, then it creates '/media/$USER' and if that succeeds, it tries to set the ACL. If setting the ACL fails, you get the error from this bug report, and the directory is removed again.

Now, if '/media/$USER' does exist, Udisks does not check or try to set the ACL, so then you get no error.

My '/' and thus also '/media' are not mounted with ACL support enabled, so that's why it fails to set the ACL (and why the directory it created gets removed again).

BTW: I'm not sure why the ACL is needed, as everything seems to work without it.
And I understand even less why they don't check if the ACLs are there in case the directory already exists? (Do they assume '/media' is always a tmpfs? What if there is a user named 'cdrom' or the like?)