Prevent Apple Double files from being accessed
MacOSX use Apple Double files when extended attributes are not usable. These files bear the same name that the files they keep tabs on, with "._" prepended.
These files generate a lot of clutter when trying to debug a 9P dialog, and IMHO they are quite useless with most of 9P filesystems.
MacFUSE has a mount time option, -o noappledouble, that flat out deny any access to those files. They thus do not appear on the 9P layer.
I think there should be an option to 9pfuse to make MacFUSE use this mount time option. I'd like this option to be on by default, with a way for users who really need the Apple Double files to turn them back on.
I took a shot at writing this functionality, the following patch allow for the use of osxfuse (as MacFUSE is no longer maintained) and will disable Apple Double files by default, enabling them if the environment variable P9P_ALLOW_APPLEDOUBLE is set.
I hope it is not too bad that I did not provide two different patches, the affected code lied in the same area for both issues.